admin管理员组

文章数量:1565775

1、在使用pycharm的Structure时可以看到有这些图标
图标上的字母是简写,具体含义如下
在pycharm中是自动补全的变量的类别
p:parameter 参数
m:method 方法
c:class 类

其他的也类似,大同小异
v:variable 变量
f:function 函数

另外,字母左上角有锁的图样子的,表示权限为私有。一般不应改动。

左上角圆圈的含义:

符号左上方的蓝色气泡表示该符号名以两个下划线开始和结束,由解释器和标准库进行特殊处理。

2、函数和方法的区别

与类和实例无绑定关系的function都属于函数(function);
与类和实例有绑定关系的function都属于方法(method)。


符号含义官方解释

Common

Icon

Description

Python script

Class

Method

Function

Field

Variable

Property

Parameter

Element

Project structure

Directory

Package

Source root

Excluded root

Template roots

Visibility modifiers

private

protected

public

The lock decorator in the upper-left part of a symbol marks a symbol whose name begins with one or more underscores. Such names are considered pseudo-private and are specially treated by an interpreter to restrict their visibility scope.

The blue bubble in the upper-left part of a symbol marks a symbol whose name begins and ends with two underscores, and is specially treated by an interpreter and standard library.

Bookmarks

Anonymous bookmark – a check sign bookmark. Bookmarks are used for quick navigation within a file or across the entire project.

Lettered mnemonic bookmark – a letter in the interval from A to Z.

Numbered mnemonic bookmark – a number in the interval from 0 to 9.

@property语法创建的方法【自己称之为属性方法】,会显示为紫色圆圈上方+向右的箭头。同时,以@方法名.setter对这个属性方法赋值,显示为紫色圆圈上方+向左的箭头。如下图(来自\Lib\site-packages\plotly\graph_objs_scatter3d.py):


这里@的用法参见这里

Data Sources

Icon

Description

Access Method

Aggregate

Alias Type

Argument

Body

Check

Cluster

Collation

Collection Type

Column. For more information about column icon combinations, see Possible icon combinations for columns.

Data File

Database

Read-only status

DDL data source

Default

Exception

Extension

External Schema

Foreign Data Wrapper

Foreign Key

Foreign Table

Index

Key

Materialized Log

Materialized View

Object Attribute

Object Type

Operator

Package

Projection

Read-only data sources

Role

Routine

Rule

Scheduled Event

Schema

Sequence

Server

Stored procedure or function

Synonym

Table

Table Type

Tablespace

Trigger

User

User Mapping

Variable

View

Virtual Table

官方解释链接

https://www.jetbrains/help/pycharm/symbols.html#file-types

本文标签: 图标含义窗口中pycharmStructure