private string GetTypeId(Type type, bool explicitOnly) { JsonContainerAttribute jsonContainerAttribute = JsonTypeReflector.GetJsonContainerAttribute(type); if (jsonContainerAttribute != null && !string.IsNullOrEmpty(jsonContainerAttribute.Id)) { return(jsonContainerAttribute.Id); } if (explicitOnly) { return(null); } UndefinedSchemaIdHandling undefinedSchemaIdHandling = this.UndefinedSchemaIdHandling; if (undefinedSchemaIdHandling == UndefinedSchemaIdHandling.UseTypeName) { return(type.get_FullName()); } if (undefinedSchemaIdHandling != UndefinedSchemaIdHandling.UseAssemblyQualifiedName) { return(null); } return(type.get_AssemblyQualifiedName()); }
// Token: 0x0600118D RID: 4493 RVA: 0x000616F0 File Offset: 0x0005F8F0 private string GetTypeId(Type type, bool explicitOnly) { JsonContainerAttribute cachedAttribute = JsonTypeReflector.GetCachedAttribute <JsonContainerAttribute>(type); if (!StringUtils.IsNullOrEmpty((cachedAttribute != null) ? cachedAttribute.Id : null)) { return(cachedAttribute.Id); } if (explicitOnly) { return(null); } UndefinedSchemaIdHandling undefinedSchemaIdHandling = this.UndefinedSchemaIdHandling; if (undefinedSchemaIdHandling == UndefinedSchemaIdHandling.UseTypeName) { return(type.FullName); } if (undefinedSchemaIdHandling != UndefinedSchemaIdHandling.UseAssemblyQualifiedName) { return(null); } return(type.AssemblyQualifiedName); }