Firstborn/Library/PackageCache/com.unity.ads@4.4.2/Editor/Parser/SkAdNetworkParser.cs
Schaken-Mods 9092858a58 updated to the latest editor
I updated everything to the latest Unity Editor. Also realized I had the wrong shaders on my hairs, those are fixed and the hairs look MUCH better!
2023-05-07 17:43:11 -05:00

31 lines
990 B
C#

using System;
using System.Collections.Generic;
namespace UnityEngine.Advertisements.Editor {
internal static class SkAdNetworkParser {
private static Dictionary<string, ISkAdNetworkParser> s_Parsers;
static SkAdNetworkParser() {
s_Parsers = new Dictionary<string, ISkAdNetworkParser> {
{ SkAdNetworkFileExtension.XML, new SkAdNetworkXmlParser() },
{ SkAdNetworkFileExtension.JSON, new SkAdNetworkJsonParser() },
{ SkAdNetworkFileExtension.NONE, new SkAdNetworkUrlParser() }
};
}
public static ISkAdNetworkParser GetParser(string parserType)
{
try {
s_Parsers.TryGetValue(parserType, out var parser);
return parser;
}
catch (Exception) { }
return null;
}
public static IEnumerable<ISkAdNetworkParser> GetAllParsers() {
return s_Parsers.Values;
}
}
}