build/lib/policies.ts/StringEnumPolicy/from
class StringEnumPolicy:	static from(
		name: string,
		category: Category,
		minimumVersion: string,
		description: NlsString,
		moduleName: string,
		settingNode: Parser.SyntaxNode
	): StringEnumPolicy | undefined {
		const type = getStringProperty(settingNode, 'type');

		if (type !== 'string') {
			return undefined;
		}

		const enum_ = getStringArrayProperty(settingNode, 'enum');

		if (!enum_) {
			return undefined;
		}

		if (!isStringArray(enum_)) {
			throw new Error(`Property 'enum' should not be localized.`);
		}

		const enumDescriptions = getStringArrayProperty(settingNode, 'enumDescriptions');

		if (!enumDescriptions) {
			throw new Error(`Missing required 'enumDescriptions' property.`);
		} else if (!isNlsStringArray(enumDescriptions)) {
			throw new Error(`Property 'enumDescriptions' should be localized.`);
		}

		return new StringEnumPolicy(name, category, minimumVersion, description, moduleName, enum_, enumDescriptions);
	}