Table of Contents

Class BuilderBase<TEndpoint>

Namespace
TypedRest.CodeGeneration.CSharp.Endpoints
Assembly
TypedRest.CodeGeneration.CSharp.dll

Common base class for IBuilder<TEndpoint>s.

public abstract class BuilderBase<TEndpoint> : IBuilder<TEndpoint>, IBuilder where TEndpoint : IEndpoint

Type Parameters

TEndpoint

The type of IEndpoint to generate code for.

Inheritance
object
BuilderBase<TEndpoint>
Implements
IBuilder<TEndpoint>
Derived

Methods

Build(string, IEndpoint, IEndpointGenerator)

public (CSharpProperty property, IEnumerable<ICSharpType> types) Build(string key, IEndpoint endpoint, IEndpointGenerator generator)

Parameters

key string
endpoint IEndpoint
generator IEndpointGenerator

Returns

(CSharpProperty property, IEnumerable<ICSharpType> types)

Build(string, TEndpoint, IEndpointGenerator)

public (CSharpProperty property, IEnumerable<ICSharpType> types) Build(string key, TEndpoint endpoint, IEndpointGenerator generator)

Parameters

key string
endpoint TEndpoint
generator IEndpointGenerator

Returns

(CSharpProperty property, IEnumerable<ICSharpType> types)

GetAdditional(string, TEndpoint, IEndpointGenerator)

protected virtual (IEnumerable<ICSharpType> types, IEnumerable<CSharpIdentifier> typeArguments) GetAdditional(string key, TEndpoint endpoint, IEndpointGenerator generator)

Parameters

key string
endpoint TEndpoint
generator IEndpointGenerator

Returns

(IEnumerable<ICSharpType> types, IEnumerable<CSharpIdentifier> typeArguments)

GetImplementationType(TEndpoint, INamingStrategy)

protected abstract CSharpIdentifier GetImplementationType(TEndpoint endpoint, INamingStrategy naming)

Parameters

endpoint TEndpoint
naming INamingStrategy

Returns

CSharpIdentifier

GetInterfaceType(CSharpIdentifier, bool)

protected virtual CSharpIdentifier GetInterfaceType(CSharpIdentifier implementationType, bool withInterfaces)

Parameters

implementationType CSharpIdentifier
withInterfaces bool

Returns

CSharpIdentifier

GetParameters(TEndpoint)

protected virtual IEnumerable<CSharpParameter> GetParameters(TEndpoint endpoint)

Parameters

endpoint TEndpoint

Returns

IEnumerable<CSharpParameter>