Interface IEndpointGenerator
- Namespace
- TypedRest.CodeGeneration.Jvm.Endpoints
- Assembly
- TypedRest.CodeGeneration.Jvm.dll
Drives the generation of code for a tree of IEndpoints.
public interface IEndpointGenerator
Properties
Log
Collects messages about aspects of the document the target language cannot express.
IGenerationLog Log { get; }
Property Value
Naming
Decides what the generated types and members are called.
INamingStrategy Naming { get; }
Property Value
WithInterfaces
Indicates whether an interface is generated alongside each generated endpoint class.
bool WithInterfaces { get; }
Property Value
Remarks
When on, generated classes take the Impl suffix and the interface keeps the plain name. When off,
the class keeps the plain name and no interface is generated.
Methods
EndpointType(string, IEndpoint)
Reserves a unique name for a generated endpoint class.
JvmIdentifier EndpointType(string key, IEndpoint endpoint)
Parameters
Returns
Generate(string, IEndpoint)
Generates the member exposing an endpoint on its parent, plus any types needed for it.
(JvmChildEndpoint child, IEnumerable<IJvmType> types) Generate(string key, IEndpoint endpoint)
Parameters
Returns
PopParent()
Records that generation has left the children of the most recently pushed endpoint.
void PopParent()
PushParent(string)
Records that generation has descended into the children of the endpoint with this key.
void PushParent(string key)
Parameters
keystring