SpecificationResultGenerator.

GetTypeShortName(Type) Method

Summary

Get short name of type - without namespaces etc.

Syntax

[PublicAPI]
[NotNull]
public static string GetTypeShortName(Type type)

Examples

SpecificationResultGenerator.GetTypeShortName(typeof(List<int[]>)) // List<Int32[]>

Attributes

Type Description
PublicAPI
NotNull

Parameters

Name Type Description
type Type Get name of.

Return Value

Type Description
string Short name of type.

Exceptions

Type Description
System.ArgumentNullException Thrown when type is null.
System.InvalidOperationException Thrown when type is array and GetElementType return null.
GitHub