我爱占星网 我爱占星网
首页
编程
java
php
前端
首页 编程 java php 前端

在Go中命名以小写字母开头的专有名词[关闭]

How do you name a type if it should be public/exported and the name should stand for: iPhoneX, iOS, eBay, etc.

Do you name them IPhoneX and IOS? or how do you name a type if the name in real world starts with lowercase letter?

You need to start the name with uppercase letter if you want to have it exported anyway, so I would say that your proposed names would be fine for cases in which you need such names.

近期文章

  • 了解时间包的golang日期格式
  • Go中的json序列化后的匿名结构
  • 从另一个本地包导入本地包
  • 类型断言非简约[重复]
  • Golang:创建切片结构
  • 包级收集
  • 如何在golang中的F2()之前调用函数F1()
  • 使用goroutine插入地图的问题
  • 来自不同文件的全局变量Golang
  • 如何在Golang中正确使用可变参数args?
  • json.Unmarshal接口指针,带有更高类型的断言
  • 无法创建在线网页
  • 解决非主包中的相对路径的问题
  • go-修改切片的指针不会修改原始的
  • 如何组合2个结构内容,其中一个具有相同的键
  • 如何将JSON数组转换为对象
  • 在HTTP响应中对分块数据如何设置Content-Length
  • 在Golang中初始化新类(将Java转换为Golang)
  • 发送带有正文的HEAD http请求导致net / http错误
  • 如何比较两个值为结构但作为接口返回的值

Copyright ©2022 我爱占星 All Rights Reserved.

浙ICP备2022030071号-1

部分图文来自网络,如有侵犯您的版权,请告诉我们删除

友情链接:代码精华