Ejemplo n.º 1
0
 public override void OnConfigure(
     IDescriptorContext context,
     IEnumTypeDescriptor descriptor,
     Type type)
 {
     descriptor.Name("Abc");
 }
Ejemplo n.º 2
0
        protected override void Configure(IEnumTypeDescriptor <GeoJsonGeometryType> descriptor)
        {
            descriptor
            .Name(EnumTypeTypeName)
            .BindValuesExplicitly();

            descriptor
            .Value(Point)
            .Name(nameof(Point));

            descriptor
            .Value(MultiPoint)
            .Name(nameof(MultiPoint));

            descriptor
            .Value(LineString)
            .Name(nameof(LineString));

            descriptor
            .Value(MultiLineString)
            .Name(nameof(MultiLineString));

            descriptor
            .Value(Polygon)
            .Name(nameof(Polygon));

            descriptor
            .Value(MultiPolygon)
            .Name(nameof(MultiPolygon));

            descriptor
            .Value(GeometryCollection)
            .Name(nameof(GeometryCollection));
        }
Ejemplo n.º 3
0
        protected override void Configure(IEnumTypeDescriptor <TypeKind> descriptor)
        {
            descriptor.Name("__TypeKind");

            descriptor.Description(TypeResources.TypeKind_Description);

            descriptor.Item(TypeKind.Scalar)
            .Description(TypeResources.TypeKind_Scalar);

            descriptor.Item(TypeKind.Object)
            .Description(TypeResources.TypeKind_Object);

            descriptor.Item(TypeKind.Interface)
            .Description(TypeResources.TypeKind_Interface);

            descriptor.Item(TypeKind.Union)
            .Description(TypeResources.TypeKind_Union);

            descriptor.Item(TypeKind.Enum)
            .Description(TypeResources.TypeKind_Enum);

            descriptor.Item(TypeKind.InputObject)
            .Name("INPUT_OBJECT")
            .Description(TypeResources.TypeKind_InputObject);

            descriptor.Item(TypeKind.List)
            .Description(TypeResources.TypeKind_List);

            descriptor.Item(TypeKind.NonNull)
            .Name("NON_NULL")
            .Description(TypeResources.TypeKind_NonNull);
        }
 protected override void Configure(IEnumTypeDescriptor <ControllerElementType> descriptor)
 {
     descriptor.Name("ControllerElementType")
     .Description("Stone-defined semantic types for Controller Elements." +
                  "Specifies the semantics of a specific element on a controller layout.")
     .BindValues(BindingBehavior.Implicit);
 }
Ejemplo n.º 5
0
 protected override void Configure(IEnumTypeDescriptor <ControllerElement> descriptor)
 {
     descriptor.Name("ControllerElement")
     .Description("Stone-defined semantic Controller Elements. " +
                  "A Controller Element is a semantic name given to a capability of a defined Stone controller layout.")
     .BindValues(BindingBehavior.Implicit);
 }
Ejemplo n.º 6
0
        protected override void Configure(IEnumTypeDescriptor <Episode> descriptor)
        {
            descriptor
            .Name("Episode")
            .Description("One of the films in the Star Wars Trilogy.");

            descriptor.Value(Episode.NEWHOPE).Description("Released in 1977.");
            descriptor.Value(Episode.EMPIRE).Description("Released in 1980.");
            descriptor.Value(Episode.JEDI).Description("Released in 1983.");
        }
Ejemplo n.º 7
0
 public override void OnConfigure(
     IDescriptorContext context,
     IEnumTypeDescriptor descriptor,
     Type type)
 {
     if (!string.IsNullOrEmpty(Name))
     {
         descriptor.Name(Name);
     }
 }
 protected override void Configure(IEnumTypeDescriptor <EmulatorCompatibility> descriptor)
 {
     descriptor.Name("EmulatorCompatibility")
     .Description("Describes the levels of compatibility an emulator has with a given game.");
     descriptor.Value(EmulatorCompatibility.Unsupported)
     .Description("This game is not supported by this emulator.");
     descriptor.Value(EmulatorCompatibility.MissingSystemFiles)
     .Description("The system files required to run this game are not available.");
     descriptor.Value(EmulatorCompatibility.RequiresValidation)
     .Description("The game has the files required to be run, but they are not in the correct format. " +
                  "Validation should be run before launching this game.");
     descriptor.Value(EmulatorCompatibility.Ready)
     .Description("This game is supported and ready to be run, requiring no validation. ");
 }
Ejemplo n.º 9
0
        protected override void Configure(IEnumTypeDescriptor <TypeKind> descriptor)
        {
            descriptor
            .Name(Names.__TypeKind)
            .Description(TypeResources.TypeKind_Description)
            // Introspection types must always be bound explicitly so that we
            // do not get any interference with conventions.
            .BindItems(BindingBehavior.Explicit);

            descriptor
            .Item(TypeKind.Scalar)
            .Name(Names.Scalar)
            .Description(TypeResources.TypeKind_Scalar);

            descriptor
            .Item(TypeKind.Object)
            .Name(Names.Object)
            .Description(TypeResources.TypeKind_Object);

            descriptor
            .Item(TypeKind.Interface)
            .Name(Names.Interface)
            .Description(TypeResources.TypeKind_Interface);

            descriptor
            .Item(TypeKind.Union)
            .Name(Names.Union)
            .Description(TypeResources.TypeKind_Union);

            descriptor
            .Item(TypeKind.Enum)
            .Name(Names.Enum)
            .Description(TypeResources.TypeKind_Enum);

            descriptor
            .Item(TypeKind.InputObject)
            .Name(Names.InputObject)
            .Description(TypeResources.TypeKind_InputObject);

            descriptor
            .Item(TypeKind.List)
            .Name(Names.List)
            .Description(TypeResources.TypeKind_List);

            descriptor
            .Item(TypeKind.NonNull)
            .Name(Names.NonNull)
            .Description(TypeResources.TypeKind_NonNull);
        }
Ejemplo n.º 10
0
        protected override void Configure(IEnumTypeDescriptor <GameEmulationState> descriptor)
        {
            descriptor.Name("GameEmulationState")
            .Description("Describes the state of a game emulation.");
            descriptor.Value(GameEmulationState.RequiresSetupEnvironment)
            .Description(
                @"This game emulation requires environment setup. The following mutations may occur.

* `setupEmulationEnvironment`
* `cleanupEmulation`
");
            descriptor.Value(GameEmulationState.RequiresCompileConfiguration)
            .Description(
                @"The game emulation requires configuration to be compiled. The following mutations may occur.

* `compileEmulationConfiguration`
* `cleanupEmulation`
");
            descriptor.Value(GameEmulationState.RequiresRestoreSaveGame)
            .Description(
                @"The game emulation requires the save game to be restored. The following mutations may occur.

* `restoreEmulationSave`
* `cleanupEmulation`
");
            descriptor.Value(GameEmulationState.CanStartEmulation)
            .Description(
                @"The game emulation can be started. The following mutations may occur.

* `persistEmulationSave`
* `startEmulation`
* `cleanupEmulation`
");
            descriptor.Value(GameEmulationState.CanStopEmulation)
            .Description(
                @"The game emulation is running, and can be stopped. The following mutations may occur.

* `persistEmulationSave`
* `stopEmulation`
* `cleanupEmulation` will immediately stop the emulation and cleanup.
");
            descriptor.Value(GameEmulationState.RequiresDispose)
            .Description(
                @"The game emulation has been stopped, and needs cleanup. The following mutations may occur.

* `persistEmulationSave`
* `cleanupEmulation`
");
        }
Ejemplo n.º 11
0
    protected override void Configure(
        IEnumTypeDescriptor <ApplyPolicy> descriptor)
    {
        descriptor
        .Name("ApplyPolicy")
        .BindValuesExplicitly();

        descriptor
        .Value(ApplyPolicy.BeforeResolver)
        .Name("BEFORE_RESOLVER");

        descriptor
        .Value(ApplyPolicy.AfterResolver)
        .Name("AFTER_RESOLVER");
    }
Ejemplo n.º 12
0
        protected override void Configure(
            IEnumTypeDescriptor <ExecuteResolver> descriptor)
        {
            descriptor
            .Name("ExecuteResolver")
            .BindValuesExplicitly();

            descriptor
            .Value(ExecuteResolver.AfterPolicy)
            .Name("AFTER_POLICY");

            descriptor
            .Value(ExecuteResolver.BeforePolicy)
            .Name("BEFORE_POLICY");
        }
Ejemplo n.º 13
0
        protected override void Configure(IEnumTypeDescriptor <PathType> descriptor)
        {
            descriptor.Name("PathType")
            .Description("If the option is a PATH option, the type of path the option accepts as values.");

            descriptor.Value(PathType.Either)
            .Description("A contextual path that points to either a directory or a file.");
            descriptor.Value(PathType.File)
            .Description("A contextual path that points to a file.");
            descriptor.Value(PathType.Directory)
            .Description("A contextual path that points to a directory.");
            descriptor.Value(PathType.NotPath)
            .Description("Not a path.");
            descriptor.Value(PathType.Raw)
            .Description("A raw, operating-system dependent path on the realized filesystem.");
        }
Ejemplo n.º 14
0
        protected override void Configure(IEnumTypeDescriptor <TypeKind> descriptor)
        {
            descriptor.Name("__TypeKind");

            descriptor.Description(
                "An enum describing what kind of type a given `__Type` is.");

            descriptor.Item(TypeKind.Scalar)
            .Description("Indicates this type is a scalar.");

            descriptor.Item(TypeKind.Object)
            .Description("Indicates this type is an object. " +
                         "`fields` and `interfaces` are valid fields.");

            descriptor.Item(TypeKind.Interface)
            .Description("Indicates this type is an interface. " +
                         "`fields` and `possibleTypes` are valid fields.");

            descriptor.Item(TypeKind.Union)
            .Description("Indicates this type is a union. " +
                         "`possibleTypes` is a valid field.");

            descriptor.Item(TypeKind.Enum)
            .Description("Indicates this type is an enum. " +
                         "`enumValues` is a valid field.");

            descriptor.Item(TypeKind.InputObject)
            .Name("INPUT_OBJECT")
            .Description("Indicates this type is an input object. " +
                         "`inputFields` is a valid field.");

            descriptor.Item(TypeKind.List)
            .Description("Indicates this type is a list. " +
                         "`ofType` is a valid field.");

            descriptor.Item(TypeKind.NonNull)
            .Name("NON_NULL")
            .Description("Indicates this type is a non-null. " +
                         "`ofType` is a valid field.");
        }
Ejemplo n.º 15
0
 public override void OnConfigure(IEnumTypeDescriptor descriptor)
 {
     descriptor.Name("Abc");
 }
Ejemplo n.º 16
0
 protected override void Configure(IEnumTypeDescriptor <string> descriptor)
 {
     descriptor.Name("Some");
     descriptor.Value("ABC").Name("DEF");
 }
Ejemplo n.º 17
0
 protected override void Configure(IEnumTypeDescriptor <FilterOperation> descriptor)
 {
     descriptor.Name("_FilterOperation");
 }
Ejemplo n.º 18
0
 protected override void Configure(IEnumTypeDescriptor <OperationKind> descriptor)
 {
     descriptor.Name("_OperationKind");
 }
Ejemplo n.º 19
0
 protected override void Configure(IEnumTypeDescriptor <SortDirection> descriptor)
 {
     descriptor.Name("_SortDirection");
 }
Ejemplo n.º 20
0
        protected override void Configure(IEnumTypeDescriptor <DirectiveLocation> descriptor)
        {
            descriptor.Name("__DirectiveLocation");

            descriptor.Description(
                "A Directive can be adjacent to many parts of the GraphQL language, a " +
                "__DirectiveLocation describes one such possible adjacencies.");

            descriptor.Item(DirectiveLocation.Query)
            .Description("Location adjacent to a query operation.");

            descriptor.Item(DirectiveLocation.Mutation)
            .Description("Location adjacent to a mutation operation.");

            descriptor.Item(DirectiveLocation.Subscription)
            .Description("Location adjacent to a subscription operation.");

            descriptor.Item(DirectiveLocation.Field)
            .Description("Location adjacent to a field.");

            descriptor.Item(DirectiveLocation.FragmentDefinition)
            .Name("FRAGMENT_DEFINITION")
            .Description("Location adjacent to a fragment definition.");

            descriptor.Item(DirectiveLocation.FragmentSpread)
            .Name("FRAGMENT_SPREAD")
            .Description("Location adjacent to a fragment spread.");

            descriptor.Item(DirectiveLocation.InlineFragment)
            .Name("INLINE_FRAGMENT")
            .Description("Location adjacent to an inline fragment.");

            descriptor.Item(DirectiveLocation.Schema)
            .Description("Location adjacent to a schema definition.");

            descriptor.Item(DirectiveLocation.Scalar)
            .Description("Location adjacent to a scalar definition.");

            descriptor.Item(DirectiveLocation.Object)
            .Description("Location adjacent to an object type definition.");

            descriptor.Item(DirectiveLocation.FieldDefinition)
            .Name("FIELD_DEFINITION")
            .Description("Location adjacent to a field definition.");

            descriptor.Item(DirectiveLocation.ArgumentDefinition)
            .Name("ARGUMENT_DEFINITION")
            .Description("Location adjacent to an argument definition");

            descriptor.Item(DirectiveLocation.Interface)
            .Description("Location adjacent to an interface definition.");

            descriptor.Item(DirectiveLocation.Union)
            .Description("Location adjacent to a union definition.");

            descriptor.Item(DirectiveLocation.Enum)
            .Description("Location adjacent to an enum definition.");

            descriptor.Item(DirectiveLocation.EnumValue)
            .Name("ENUM_VALUE")
            .Description("Location adjacent to an enum value definition.");

            descriptor.Item(DirectiveLocation.InputObject)
            .Name("INPUT_OBJECT")
            .Description("Location adjacent to an input object type definition.");

            descriptor.Item(DirectiveLocation.InputFieldDefinition)
            .Name("INPUT_FIELD_DEFINITION")
            .Description("Location adjacent to an input object field definition.");
        }
Ejemplo n.º 21
0
 protected override void Configure(IEnumTypeDescriptor <DeviceCapability> descriptor)
 {
     descriptor.Name("DeviceCapability")
     .Description("Input device capabilities exposed by the underlying device API.")
     .BindValues(BindingBehavior.Implicit);
 }
Ejemplo n.º 22
0
 protected override void Configure(IEnumTypeDescriptor <SaveManagementStrategy> descriptor)
 {
     descriptor.Name("SaveManagementStrategy")
     .Description("Strategies used to manage save data.")
     .BindValues(BindingBehavior.Implicit);
 }
Ejemplo n.º 23
0
 protected override void Configure(IEnumTypeDescriptor <PagingKind> descriptor)
 {
     descriptor.Name("_PagingKind");
 }
Ejemplo n.º 24
0
 protected override void Configure(IEnumTypeDescriptor descriptor)
 {
     descriptor.Name("Foo");
     descriptor.Value(Foo.Bar).Ignore();
 }
Ejemplo n.º 25
0
        protected override void Configure(IEnumTypeDescriptor <DirectiveLocation> descriptor)
        {
            descriptor.Name("__DirectiveLocation");

            descriptor.Description(
                TypeResources.DirectiveLocation_Description);

            descriptor.Item(DirectiveLocation.Query)
            .Description(TypeResources.DirectiveLocation_Query);

            descriptor.Item(DirectiveLocation.Mutation)
            .Description(TypeResources.DirectiveLocation_Mutation);

            descriptor.Item(DirectiveLocation.Subscription)
            .Description(TypeResources.DirectiveLocation_Subscription);

            descriptor.Item(DirectiveLocation.Field)
            .Description(TypeResources.DirectiveLocation_Field);

            descriptor.Item(DirectiveLocation.FragmentDefinition)
            .Name("FRAGMENT_DEFINITION")
            .Description(TypeResources.DirectiveLocation_FragmentDefinition);

            descriptor.Item(DirectiveLocation.FragmentSpread)
            .Name("FRAGMENT_SPREAD")
            .Description(TypeResources.DirectiveLocation_FragmentSpread);

            descriptor.Item(DirectiveLocation.InlineFragment)
            .Name("INLINE_FRAGMENT")
            .Description(TypeResources.DirectiveLocation_InlineFragment);

            descriptor.Item(DirectiveLocation.Schema)
            .Description(TypeResources.DirectiveLocation_Schema);

            descriptor.Item(DirectiveLocation.Scalar)
            .Description(TypeResources.DirectiveLocation_Scalar);

            descriptor.Item(DirectiveLocation.Object)
            .Description(TypeResources.DirectiveLocation_Object);

            descriptor.Item(DirectiveLocation.FieldDefinition)
            .Name("FIELD_DEFINITION")
            .Description(TypeResources.DirectiveLocation_FieldDefinition);

            descriptor.Item(DirectiveLocation.ArgumentDefinition)
            .Name("ARGUMENT_DEFINITION")
            .Description(TypeResources.DirectiveLocation_ArgumentDefinition);

            descriptor.Item(DirectiveLocation.Interface)
            .Description(TypeResources.DirectiveLocation_Interface);

            descriptor.Item(DirectiveLocation.Union)
            .Description(TypeResources.DirectiveLocation_Union);

            descriptor.Item(DirectiveLocation.Enum)
            .Description(TypeResources.DirectiveLocation_Enum);

            descriptor.Item(DirectiveLocation.EnumValue)
            .Name("ENUM_VALUE")
            .Description(TypeResources.DirectiveLocation_EnumValue);

            descriptor.Item(DirectiveLocation.InputObject)
            .Name("INPUT_OBJECT")
            .Description(TypeResources.DirectiveLocation_InputObject);

            descriptor.Item(DirectiveLocation.InputFieldDefinition)
            .Name("INPUT_FIELD_DEFINITION")
            .Description(TypeResources.DirectiveLocation_InputFieldDefinition);
        }
Ejemplo n.º 26
0
 protected override void Configure(IEnumTypeDescriptor <DrinkKind> descriptor)
 {
     descriptor.Name("DrinkKind");
 }
Ejemplo n.º 27
0
 protected override void Configure(IEnumTypeDescriptor descriptor)
 {
     descriptor.Name("Foo");
     descriptor.Value(Foo.Quox).Name("_QUOX");
 }
Ejemplo n.º 28
0
        protected override void Configure(IEnumTypeDescriptor <DirectiveLocation> descriptor)
        {
            descriptor
            .Name(Names.__DirectiveLocation)
            .Description(TypeResources.DirectiveLocation_Description)
            // Introspection types must always be bound explicitly so that we
            // do not get any interference with conventions.
            .BindValues(BindingBehavior.Explicit);

            descriptor
            .Value(DirectiveLocation.Query)
            .Name(Lang.Query.Value)
            .Description(TypeResources.DirectiveLocation_Query);

            descriptor
            .Value(DirectiveLocation.Mutation)
            .Name(Lang.Mutation.Value)
            .Description(TypeResources.DirectiveLocation_Mutation);

            descriptor
            .Value(DirectiveLocation.Subscription)
            .Name(Lang.Subscription.Value)
            .Description(TypeResources.DirectiveLocation_Subscription);

            descriptor
            .Value(DirectiveLocation.Field)
            .Name(Lang.Field.Value)
            .Description(TypeResources.DirectiveLocation_Field);

            descriptor
            .Value(DirectiveLocation.FragmentDefinition)
            .Name(Lang.FragmentDefinition.Value)
            .Description(TypeResources.DirectiveLocation_FragmentDefinition);

            descriptor
            .Value(DirectiveLocation.FragmentSpread)
            .Name(Lang.FragmentSpread.Value)
            .Description(TypeResources.DirectiveLocation_FragmentSpread);

            descriptor
            .Value(DirectiveLocation.InlineFragment)
            .Name(Lang.InlineFragment.Value)
            .Description(TypeResources.DirectiveLocation_InlineFragment);

            descriptor
            .Value(DirectiveLocation.VariableDefinition)
            .Name(Lang.VariableDefinition.Value)
            .Description("Location adjacent to a variable definition.");

            descriptor
            .Value(DirectiveLocation.Schema)
            .Name(Lang.Schema.Value)
            .Description(TypeResources.DirectiveLocation_Schema);

            descriptor
            .Value(DirectiveLocation.Scalar)
            .Name(Lang.Scalar.Value)
            .Description(TypeResources.DirectiveLocation_Scalar);

            descriptor
            .Value(DirectiveLocation.Object)
            .Name(Lang.Object.Value)
            .Description(TypeResources.DirectiveLocation_Object);

            descriptor
            .Value(DirectiveLocation.FieldDefinition)
            .Name(Lang.FieldDefinition.Value)
            .Description(TypeResources.DirectiveLocation_FieldDefinition);

            descriptor
            .Value(DirectiveLocation.ArgumentDefinition)
            .Name(Lang.ArgumentDefinition.Value)
            .Description(TypeResources.DirectiveLocation_ArgumentDefinition);

            descriptor
            .Value(DirectiveLocation.Interface)
            .Name(Lang.Interface.Value)
            .Description(TypeResources.DirectiveLocation_Interface);

            descriptor
            .Value(DirectiveLocation.Union)
            .Name(Lang.Union.Value)
            .Description(TypeResources.DirectiveLocation_Union);

            descriptor
            .Value(DirectiveLocation.Enum)
            .Name(Lang.Enum.Value)
            .Description(TypeResources.DirectiveLocation_Enum);

            descriptor
            .Value(DirectiveLocation.EnumValue)
            .Name(Lang.EnumValue.Value)
            .Description(TypeResources.DirectiveLocation_EnumValue);

            descriptor
            .Value(DirectiveLocation.InputObject)
            .Name(Lang.InputObject.Value)
            .Description(TypeResources.DirectiveLocation_InputObject);

            descriptor
            .Value(DirectiveLocation.InputFieldDefinition)
            .Name(Lang.InputFieldDefinition.Value)
            .Description(TypeResources.DirectiveLocation_InputFieldDefinition);
        }
 protected override void Configure(IEnumTypeDescriptor <AccountTypeEnum> descriptor)
 {
     descriptor.Name("AccountTypeEnum");
     descriptor.Description("Enumeration for the account type object.");
 }
 protected override void Configure(IEnumTypeDescriptor <RelationshipDirection> descriptor)
 {
     descriptor.Name("_RelationshipDirection");
 }