首页 > 编程语言 >程序设计应用 2023-03-25

程序设计应用 2023-03-25

时间:2023-03-25 10:44:06浏览次数:46  
标签:03 used string 25 Matches 2023 path any types

how many types supported in url path

There are several types that can be used in URL patterns in Django. Here are some of the most commonly used types:

str: Matches any non-empty string, excluding the path separator (/).
int: Matches any positive integer.
slug: Matches any slug string consisting of ASCII letters or numbers, plus hyphens and underscores.
uuid: Matches a UUID in hexadecimal format, with or without hyphens.
path: Matches any non-empty string, including the path separator (/).
You can also define your own custom types by subclassing django.urls.converters.StringConverter and implementing the to_python and to_url methods.

 

Is uuid same as guid in C#?

UUID and GUID are similar concepts, but they are not exactly the same. UUID stands for "Universally Unique Identifier" and is a 128-bit value that is used to identify information in computer systems. GUID stands for "Globally Unique Identifier" and is a Microsoft implementation of UUIDs.

Both UUIDs and GUIDs are used to generate unique identifiers for objects, but the specific algorithms used to generate them may differ. Additionally, UUIDs are used in a variety of systems, while GUIDs are primarily used in Microsoft technologies like C#.

标签:03,used,string,25,Matches,2023,path,any,types
From: https://www.cnblogs.com/chucklu/p/17254282.html

相关文章

  • 2023 archlinux 启用 Secure Boot (安全启动) 的最简单方法 -- sbctl
    配置背景最近在我的Thinkpad上装了Windows11+Archlinux双系统。想要开启下SecureBoot。其实不开启双系统运行也正常,但由于Windows上的WSA和部分游戏的安全......
  • 做题记录 230324 // 最小生成树
    为什么擦眼睛会痛因为拭目痛いA.JungleRoadshttp://222.180.160.110:1024/contest/3452/problem/1纯最小生成树,比较坑的点是因为向POJ远程提交,所以没办法用万能头,......
  • Python - difference between '../../' and '/../../' when they are concatenated to
    scnzzh:~/aaa>catzzh1.pyimportos.pathprint(os.path.dirname(__file__))abs_file_dir=os.path.abspath(os.path.dirname(__file__))print(abs_file_dir)a=......
  • 20230325 LCD1602
    关于模块式编程:模块化编程是一种编写代码的方法,将大型程序分解成小的、独立的模块,每个模块实现特定的功能,并且可以被其他程序调用和重复使用。这种方法可以提高代码的可维......
  • vue03 01.创建项目
    目录01.创建项目打包工具vite介绍安装命令启动项目浏览效果代码目录打包预览运行01.创建项目打包工具vite官网vite介绍Vite也是前端构建工具相较于webpack,vite采......
  • P1036 [NOIP2002 普及组] 选数
    [NOIP2002普及组]选数洛谷传送门点击查看题目题目描述已知n个整数x1,x2,.....,xn,以及1个整数k(k<n)。从n个整数中任选k个整数相加,可分别得到一系列的和。例......
  • 2023、03、24学习总结
    写了第一个查询,用同样的方法写第二个线路查询出现问题,无法正常查询,明天在找问题  ......
  • 25.ElasticSearch
    简介Elastic是Lucene的封装,提供了RESTAPI的操作接口。基本概念Index(索引)动词:相当于MySql中的insert名词:相当于Mysql中的DatabaseType(类型)再Index(索引)中可以......
  • 总结20230324
    今日是周五,虽然课最多,但是还是很喜欢今天的,因为明天又迎接来了双休。今天上了计算机网络、概率论、实用英语阅读与翻译、web应用开发技术、数学建模B。计算机网络今天进......
  • 2023-03-25 AVL平衡树
    AVL平衡树1什么是AVL平衡树AVL是两个人的人名Adelson-Velsky和Landis,两个人都是俄罗斯人,是两人在1962年的论文中首次提出,是最早的自平衡二分搜索树什么是平衡二叉树......