mirror of https://github.com/apache/cloudstack.git
improvements / cleanup
This commit is contained in:
parent
958e1b47f3
commit
5482fdfa6c
|
|
@ -97,10 +97,8 @@ public class ApiXmlDocWriter {
|
|||
if (curCmd.isAssignableFrom(cmdClass)) {
|
||||
// api_cmd map always keep the admin cmd class to get full response and parameters
|
||||
s_apiNameCmdClassMap.put(apiName, cmdClass);
|
||||
} else if (cmdClass.isAssignableFrom(curCmd)) {
|
||||
System.out.println("Info: API Cmd class " + cmdClass.getName() + " is assignable from " + curCmd.getName() + ", skip this one");
|
||||
} else {
|
||||
System.out.println("Warning: API Cmd class " + cmdClass.getName() + " has non-unique apiname " + apiName);
|
||||
} else if (!cmdClass.isAssignableFrom(curCmd)) {
|
||||
System.out.println("Warning: API Cmd class " + cmdClass.getName() + " has non-unique api name " + apiName);
|
||||
}
|
||||
} else {
|
||||
s_apiNameCmdClassMap.put(apiName, cmdClass);
|
||||
|
|
|
|||
|
|
@ -46,9 +46,7 @@ dirname_to_dirname = {
|
|||
|
||||
|
||||
known_categories = {
|
||||
# Use the category definition formats below:
|
||||
# keyword or api: category - to choose category based on keyword or api in the api call
|
||||
# api: (category, True|False) - True - use the category defined (i.e. direct api to category mapping), False - choose category same as above
|
||||
# Category definition format: api keyword or api name: category
|
||||
'Cisco' : 'External Device',
|
||||
'SystemVm': 'System VM',
|
||||
'VirtualMachine': 'Virtual Machine',
|
||||
|
|
@ -129,8 +127,6 @@ known_categories = {
|
|||
'saml': 'Authentication',
|
||||
'getSPMetadata': 'Authentication',
|
||||
'listIdps': 'Authentication',
|
||||
# 'authorizeSamlSso': 'Authentication',
|
||||
# 'listSamlAuthorization': 'Authentication',
|
||||
'oauthlogin': 'Authentication',
|
||||
'OauthProvider': 'OAuth',
|
||||
'quota': 'Quota',
|
||||
|
|
@ -206,8 +202,8 @@ known_categories = {
|
|||
'UnmanagedInstance': 'Virtual Machine',
|
||||
'Kubernetes': 'Kubernetes Service',
|
||||
'Rolling': 'Rolling Maintenance',
|
||||
'vsphereStoragePolicy' : 'vSphere storage policies',
|
||||
'vsphereStoragePolicies' : 'vSphere storage policies',
|
||||
'vsphereStoragePolicy' : 'vSphere Storage Policies',
|
||||
'vsphereStoragePolicies' : 'vSphere Storage Policies',
|
||||
'createConsoleEndpoint': 'Console Session',
|
||||
'listConsoleSessions': 'Console Session',
|
||||
'importVm': 'Virtual Machine',
|
||||
|
|
@ -238,23 +234,12 @@ known_categories = {
|
|||
'CustomAction' : 'Extension'
|
||||
}
|
||||
|
||||
|
||||
categories = {}
|
||||
|
||||
choosing_category = 1
|
||||
|
||||
|
||||
def choose_category(fn):
|
||||
global choosing_category
|
||||
print("choosing_category - " + str(choosing_category) + " , for fn: " + fn)
|
||||
choosing_category = choosing_category + 1
|
||||
possible_known_categories = []
|
||||
i = 1
|
||||
for k, v in known_categories.items():
|
||||
print(str(i) + " - k:" + k + ", v:" + v + " fn: " + fn + "\n")
|
||||
i = i + 1
|
||||
if k.lower() in fn.lower():
|
||||
print("add to possible_known_categories - " + k + "\n")
|
||||
possible_known_categories.append(k)
|
||||
|
||||
if len(possible_known_categories) > 0:
|
||||
|
|
|
|||
|
|
@ -61,16 +61,10 @@ version="1.0">
|
|||
<p></p>
|
||||
<h1><xsl:value-of select="name"/></h1>
|
||||
<xsl:if test="sinceVersion">
|
||||
<h1>(since: <xsl:value-of select="sinceVersion"/>)</h1>
|
||||
<h2>(since: <xsl:value-of select="sinceVersion"/>)</h2>
|
||||
<h2>since: <xsl:value-of select="sinceVersion"/></h2>
|
||||
<h3>(since: <xsl:value-of select="sinceVersion"/>)</h3>
|
||||
</xsl:if>
|
||||
<span>
|
||||
<xsl:value-of select="description"/>
|
||||
<xsl:if test="sinceVersion">
|
||||
<xsl:text> </xsl:text>(since: <xsl:value-of select="sinceVersion"/>)
|
||||
</xsl:if>
|
||||
</span>
|
||||
</xsl:for-each>
|
||||
</div>
|
||||
|
|
@ -101,9 +95,6 @@ version="1.0">
|
|||
<td style="width:500px;">
|
||||
<strong>
|
||||
<xsl:value-of select="description"/>
|
||||
<xsl:if test="sinceVersion">
|
||||
<xsl:text> </xsl:text>(since: <xsl:value-of select="sinceVersion"/>)
|
||||
</xsl:if>
|
||||
</strong>
|
||||
</td>
|
||||
<td style="width:180px;"><strong><xsl:value-of select="required"/></strong></td>
|
||||
|
|
@ -118,9 +109,6 @@ version="1.0">
|
|||
<td style="width:500px;">
|
||||
<i>
|
||||
<xsl:value-of select="description"/>
|
||||
<xsl:if test="sinceVersion">
|
||||
<xsl:text> </xsl:text>(since: <xsl:value-of select="sinceVersion"/>)
|
||||
</xsl:if>
|
||||
</i>
|
||||
</td>
|
||||
<td style="width:180px;"><i><xsl:value-of select="required"/></i></td>
|
||||
|
|
@ -149,9 +137,6 @@ version="1.0">
|
|||
</td>
|
||||
<td style="width:500px;">
|
||||
<xsl:value-of select="description"/>
|
||||
<xsl:if test="sinceVersion">
|
||||
<xsl:text> </xsl:text>(since: <xsl:value-of select="sinceVersion"/>)
|
||||
</xsl:if>
|
||||
</td>
|
||||
<xsl:for-each select="./arguments/arg">
|
||||
<tr>
|
||||
|
|
@ -168,9 +153,6 @@ version="1.0">
|
|||
<td style="width:165px; padding-left:40px;"><xsl:value-of select="name"/></td>
|
||||
<td style="width:500px;">
|
||||
<xsl:value-of select="description"/>
|
||||
<xsl:if test="sinceVersion">
|
||||
<xsl:text> </xsl:text>(since: <xsl:value-of select="sinceVersion"/>)
|
||||
</xsl:if>
|
||||
</td>
|
||||
</tr>
|
||||
</xsl:for-each>
|
||||
|
|
|
|||
Loading…
Reference in New Issue