-
Notifications
You must be signed in to change notification settings - Fork 280
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Custom extension of DocJavaMethod. #488
Comments
@younker99 You can supplement the examples in the test project at https://github.com/smart-doc-group/smart-doc-example-cn first. Wouldn't it be better to rename ICusJavaMethodExtension to ICustomJavaMethodHandler, as smart-doc does not advocate for using non-generic terms that are too specific? Start by adding examples and then submit a PR. |
@shalousun |
merged |
Summary(关于这个pr的描述)
Before converting List to List, invoke custom extensions for adjustments.
在
List<DocJavaMethod>
转化为List<ApiMethodDoc>
前,调用自定义的拓展进行调整。`Basic example(pr的用例)
Preliminary design is as follows:
ICusJavaMethodExtension
with the content beingList<DocJavaMethod> apply(JavaClass cls, List<DocJavaMethod> methodList)
.ICusJavaMethodExtension cusJavaMethodExtension
attribute toApiConfig
.IRestDocTemplate
, before convertingList<DocJavaMethod>
toList<ApiMethodDoc>
within thebuildEntryPointMethod
, check and invokecusJavaMethodExtension
to update theList<DocJavaMethod>
.初步设计是
ICusJavaMethodExtension
,内容为List<DocJavaMethod> apply(JavaClass cls, List<DocJavaMethod> methodList)
List<DocJavaMethod>
转化为List<ApiMethodDoc>
前,判断并调用cusJavaMethodExtension,更新List<DocJavaMethod>
Motivation(提出这个pr目的)
The common controller encapsulated in the project features multiple levels of inheritance, with some methods having dynamic return types and parameters. The type information parsed by smart-doc for these interfaces is inaccurate and cannot be adjusted.
项目中封装的通用controller存在多层继承,部分method的返回值和入参是动态类型,此部分接口smart-doc解析出的类型信息不准确,却又无法调整。
The text was updated successfully, but these errors were encountered: