原文地址:http://www.wholetomato.com/products/features/vasnippets.asp
| Reserved String | Meaning | |
|---|---|---|
| Date | $DATE$ | Year/month/day formatted as %04d/%02d/%02d |
| $DATE_LOCALE$ | Current date in locale format | |
| $DAY$ | Day of month formatted as %d | |
| $DAY_02$ | Day of month formatted as %02d | |
| $DAYNAME$ | Day abbreviation in locale format | |
| $DAYLONGNAME$ | Full name of day in locale format | |
| $MONTH$ | Month formatted as %d | |
| $MONTH_02$ | Month formatted as %02d | |
| $MONTHNAME$ | Month abbreviation in locale format | |
| $MONTHLONGNAME$ | Full name of month in locale format | |
| $YEAR$ | Year formatted as %d | |
| $YEAR_02$ | Year formatted as %02d | |
| Time | $HOUR$ | Hour formatted as %d |
| $HOUR_02$ | Hour formatted as %02d | |
| $MINUTE$ | Minute formatted as %02d | |
| $SECOND$ | Second formatted as %02d | |
| File | $FILE$ | Full filename with path* |
| $FILE_UPPER$ | Full filename with path in uppercase* | |
| $FILE_BASE$ | Filename without path or extension* | |
| $FILE_BASE_UPPER$ | Filename without path or extension in upper case* | |
| $FILE_EXT$ | Filename extension* | |
| $FILE_EXT_UPPER$ | Filename extension in upper case* | |
| $FILE_PATH$ | Path of file* | |
| $FILE_PATH_UPPER$ | Path of file in upper case* | |
| General | $clipboard$ | Current clipboard |
| $end$ | Position of caret after expansion | |
| $selected$ | Current selection** | |
| $$ | Literal '$' character | |
| Symbol Context | $MethodName$ | Name of containing method |
| $MethodArgs$ | Method parameters | |
| $ClassName$ | Name of containing class | |
| $BaseClassName$ | Name of base class of containing class | |
| $NamespaceName$ | Fully qualified namespace name | |
| GUID | $GUID_DEFINITION$ | Generated GUID formatted for use in a definition |
| $GUID_STRING$ | Generated GUID formatted for use in a string | |
| $GUID_STRUCT$ | Generated GUID formatted for use in a struct | |
| $GUID_SYMBOL$ | Generated GUID formatted with underscores | |
| $GUID_STRING_UPPER$ | Uppercase version of $GUID_STRING$ | |
| $GUID_STRUCT_UPPER$ | Uppercase version of $GUID_STRUCT$ | |
| $GUID_SYMBOL_UPPER$ | Uppercase version of $GUID_SYMBOL$ | |
| The following reserved strings are available only in refactoring snippets | ||
| Refactor | $GeneratedPropertyName$ | Property name generated during Encapsulate Field |
| $generatedPropertyName$ | Same as $GeneratedPropertyName$ but with lower-case first letter | |
| $MethodArg$ | One parameter of the method and its type | |
| $MethodArgName$ | One parameter of the method | |
| $MethodArgType$ | Type of one parameter of the method | |
| $MethodBody$ | Body of implementation | |
| $MethodQualifier$ | Optional qualifiers of method | |
| $ParameterList$ | Parameters separated by commas | |
| $SymbolContext$ | Context and name of method | |
| $SymbolName$ | Name of method | |
| $SymbolPrivileges$ | Access of method | |
| $SymbolStatic$ | Keyword static or blank | |
| $SymbolType$ | Return type of method | |
| $SymbolVirtual$ | Keyword virtual or blank | |
*Reserved strings beginning with $FILE expand using the case of the current file.
**Omitted from expanded code if there is no selection.
VA Snippets entries containing $GUID_* are available in IDL files.
本文介绍VASnippets中使用的各种预留字符串及其含义,包括日期、时间、文件相关信息及通用变量等。这些字符串用于自动完成代码片段,提高开发效率。

被折叠的 条评论
为什么被折叠?



