skills/cola-java/cola-naming/SKILL.md
在 COLA 架构项目中,指导新类、接口、方法的命名,确保符合项目已有的命名约定。
npx skillsauth add leikegeek/coding-exoskeleton cola-namingInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
当用户需要在 COLA 架构项目中创建新类、接口或方法时,指导其使用正确的命名约定,与项目已有风格保持一致。
在执行本 skill 之前,先检查项目的技术栈声明:
AGENTS.md 文件techStack 字段或"技术栈"章节cola-java:继续执行本 skillcola-java:跳过本 skill,不应用 COLA 命名规范AGENTS.md 不存在:跳过本 skill,建议用户先执行 /init| 层级 | 类型 | 命名规则 | 路径/说明 | 示例 |
|------|------|----------|-----------|------|
| adapter | API Controller | XxxApiController | controller/api/模块名/,URL /api/ | AiTitleBuildApiController |
| adapter | 页面 Controller | XxxController | controller/web/模块名/,URL /web/ | AmazonStockBlackController |
| adapter | 内部服务入口 | XxxCenterController | controller/center/模块名/,URL /center/ | AmazonFbaStockOutViewController |
| adapter | MQ 消费者 | XxxConsumer | consumer/模块名/ | AdjustPriceStrategyConsumer |
| adapter | 定时任务 | XxxScheduler | scheduler/模块名/ | InventorySyncScheduler |
| application | 命令执行器 | XxxCmdExe | executor/模块名/cmd/ | AdjustPriceBatchCmdExe |
| application | 查询执行器 | XxxQryExe | executor/模块名/qry/ | FbaAsinDataQryExe |
| application | 服务编排 | XxxService | service/模块名/ | OrderService |
| infrastructure | Gateway 接口 | IXxxGateway | gateway/模块名/ | IAdjustPriceStrategyGateway |
| infrastructure | Gateway 实现 | XxxGateway | gateway/模块名/impl/ | AdjustPriceStrategyGateway |
| infrastructure | MyBatis Mapper | IXxxRepository | repository/模块名/ | IOrderRepository |
| infrastructure | 数据对象 | XxxDO | dataobject/模块名/ | OrderDO |
| infrastructure | 转换器 | XxxConvertor | convertor/模块名/ | OrderConvertor |
| client | API 接口 | IXxxApi | 模块名/api/ | IAmazonFbaVineReasonsApi |
| client | 命令 DTO | XxxCmd / XxxQry | 模块名/command/ | AmazonFbaVineReasonsAddCmd |
| client | 返回 DTO | XxxDTO | 模块名/dto/ | AmazonFbaVineReasonsDTO |
@author,只读取全局用户配置 ~/.cursor/coding-exoskeleton/user-config.json;修改已有类时不新增或改写作者注释在编码阶段,当需要创建新类时,参照以上规则确定命名。如果现有项目中有偏差(已有类名不符合规范),以项目已有风格为准,保持一致性。
development
将本地 /code 流程产物、Git 可获取变更或 GitLab Merge Request 链接归一化为统一 AuditContext,供 audit-reviewer 执行业务、质量、安全一体化审计。
tools
在 Vue 3 项目中新增或改造弹窗、表单、导入流程、编辑回填、保存提交和关闭刷新链路时使用。强调独立 Dialog、本地表单状态和封装组件优先。
development
在 Vue 3 + TypeScript 项目中新增或修改 SFC、组合式逻辑、Element Plus/Sh* 包装组件、表格和页面组件时使用。强调 Composition API、组件契约和最小改动。
development
在 Vue 3 项目中接入 swagger/codegen 生成 API、核对生成目录、临时补充接口或替换页面内请求时使用。强调不手改生成物和契约收敛。