Class CsharpDocumentGenerate
java.lang.Object
com.iohao.net.extension.codegen.CsharpDocumentGenerate
- All Implemented Interfaces:
DocumentGenerate
Generate C# code, such as broadcast, error code, action
- Since:
- 21.20
- Author:
- 渔民小镇
- date:
- 2024-11-15
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidGenerates the document.protected voidgenerateAction(Document document) protected voidgenerateBroadcast(Document document) protected voidgenerateErrorCode(Document document) voidsetInternalErrorCode(boolean internalErrorCode) true : generate ActionErrorEnumvoidsetNamespace(String namespace) c# namespace that generate filesvoidThe storage path of the generated files.voidsetPublicActionCmdName(boolean publicActionCmdName) your .proto pathvoidsetTypeMappingDocument(TypeMappingDocument typeMappingDocument)
-
Constructor Details
-
CsharpDocumentGenerate
public CsharpDocumentGenerate()
-
-
Method Details
-
generate
Description copied from interface:DocumentGenerateGenerates the document.- Parameters:
document- document
-
generateErrorCode
-
generateAction
-
generateBroadcast
-
setNamespace
c# namespace that generate files -
setInternalErrorCode
public void setInternalErrorCode(boolean internalErrorCode) true : generate ActionErrorEnum -
setPublicActionCmdName
public void setPublicActionCmdName(boolean publicActionCmdName) your .proto path -
setPath
The storage path of the generated files. By default, it will be generated in the ./target/action directory -
setTypeMappingDocument
-