src/Microsoft.OpenApi.OData.Reader/Generator/OpenApiExampleGenerator.cs
/// <summary>
/// Create the dictionary of <see cref="OpenApiExample"/> object.
/// </summary>
/// <param name="context">The OData to Open API context.</param>
/// <param name="securitySchemes">The securitySchemes.</param>
/// <returns>The created <see cref="OpenApiExample"/> dictionary.</returns>
Create the dictionary of  object.
Create the dictionary of object .
public static IDictionary<string, OpenApiExample> CreateExamples(this ODataContext context)
        {
            Utils.CheckArgumentNull(context, nameof(context));
            IDictionary<string, OpenApiExample> examples = new Dictionary<string, OpenApiExample>();
            foreach (var element in context.Model.SchemaElements.Where(c => !c.Namespace.StartsWith("Org.OData.")))
            {
                switch (element.SchemaElementKind)
                {
                    case EdmSchemaElementKind.TypeDefinition: 
                        {
                            IEdmType reference = (IEdmType)element;
                            OpenApiExample example = context.CreateExample(reference);
                            if (example != null)
                            {
                                examples.Add(reference.FullTypeName(), example);
                            }
                        }
                        break;
                }
            }
            return examples;
        }
public static IDictionary < string , OpenApiExample > CreateExamples ( this ODataContext context ) { Utils . CheckArgumentNull ( context , nameof ( context ) ) ; IDictionary < string , OpenApiExample > examples = new Dictionary < string , OpenApiExample > ( ) ; foreach ( var element in context . Model . SchemaElements . Where ( c => ! c . Namespace . StartsWith ( " " ) ) ) { switch ( element . SchemaElementKind ) { case EdmSchemaElementKind . TypeDefinition : { IEdmType reference = ( IEdmType ) element ; OpenApiExample example = context . CreateExample ( reference ) ; if ( example != null ) { examples . Add ( reference . FullTypeName ( ) , example ) ; } } break ; } } return examples ; }
Create the dictionary of  object.
Create the dictionary of object .
// Each entity type, complex type, enumeration type, and type definition directly // or indirectly used in the paths field is represented as a name / value pair of the schemas map. // Type definition
The created  dictionary.
The created dictionary .
ODataContext
this
context
The OData to Open API context.
The OData to Open API context .
securitySchemes
None