CommonJsGenerator
Assembly: ServiceStack.dll
View Source
Declaration
public class CommonJsGenerator : ILangGenerator
Properties
BatchSize
Split assignment expression into smaller batches to avoid "Uncaught RangeError: Maximum call stack size exceeded" in Chrome/Blink
View Source
Declaration
public static int BatchSize { get; set; }
WithoutOptions
View Source
Declaration
public bool WithoutOptions { get; set; }
AddQueryParamOptions
View Source
Declaration
public List<string> AddQueryParamOptions { get; set; }
AllTypes
View Source
Declaration
public List<MetadataType> AllTypes { get; set; }
FilterTypes
View Source
Declaration
public static Func<List<MetadataType>, List<MetadataType>> FilterTypes { get; set; }
DictionaryDeclaration
View Source
Declaration
public string DictionaryDeclaration { get; set; }
AddedDeclarations
View Source
Declaration
public HashSet<string> AddedDeclarations { get; set; }
InsertCodeFilter
Add Code to top of generated code
View Source
Declaration
public static AddCodeDelegate InsertCodeFilter { get; set; }
AddCodeFilter
Add Code to bottom of generated code
View Source
Declaration
public static AddCodeDelegate AddCodeFilter { get; set; }
Gen
View Source
Declaration
public TypeScriptGenerator Gen { get; set; }
ReturnTypeFilter
View Source
Declaration
public Func<string, string> ReturnTypeFilter { get; set; }
Fields
Config
View Source
Declaration
public readonly MetadataTypesConfig Config
Methods
DefaultFilterTypes(List<MetadataType>)
View Source
Declaration
public static List<MetadataType> DefaultFilterTypes(List<MetadataType> types)
Returns
System.Collections.Generic.List<ServiceStack.MetadataType>
Parameters
Type | Name |
---|---|
System.Collections.Generic.List<ServiceStack.MetadataType> | types |
Type(String, String[])
View Source
Declaration
public string Type(string type, string[] genericArgs)
Returns
System.String
Parameters
Type | Name |
---|---|
System.String | type |
System.String[] | genericArgs |
DeclarationType(String, String[], out String)
View Source
Declaration
public string DeclarationType(string type, string[] genericArgs, out string addDeclaration)
Returns
System.String
Parameters
Type | Name |
---|---|
System.String | type |
System.String[] | genericArgs |
System.String | addDeclaration |
GetCode(MetadataTypes, IRequest, INativeTypesMetadata)
View Source
Declaration
public string GetCode(MetadataTypes metadata, IRequest request, INativeTypesMetadata nativeTypes)
Returns
System.String
Parameters
Type | Name |
---|---|
ServiceStack.MetadataTypes | metadata |
ServiceStack.Web.IRequest | request |
ServiceStack.NativeTypes.INativeTypesMetadata | nativeTypes |
CreateEmptyClass(String)
View Source
Declaration
public static string CreateEmptyClass(string name)
Returns
System.String
Parameters
Type | Name |
---|---|
System.String | name |