Edit

Share via


ExtensionServiceCreator Class

Definition

Class used to generate service scripts and profile instances. Primarily designed for in-editor use

public ref class ExtensionServiceCreator
public class ExtensionServiceCreator
type ExtensionServiceCreator = class
Public Class ExtensionServiceCreator
Inheritance
ExtensionServiceCreator

Constructors

ExtensionServiceCreator()

Properties

CreationLog

Log of errors and updates thus far in the create operation of the new extension service classes

InspectorFolderObject

Unity object pointing to folder asset to place Inspector class file, if applicable

InspectorName

Name of Unity inspector class to create. Value is ServiceName concatenated with "Inspector"

InterfaceFolderObject

Unity object pointing to folder asset to place interface file, if applicable

InterfaceName

Name of interface to create for new extension service. Value is ServiceName with leading "I"

Namespace

Namespace to utilize for all classes

Platforms

Supported platform flags for new extension service. Added to attribute on service class

ProfileAssetFolderObject

Unity object pointing to folder asset to place ScriptableObject profile asset file, if applicable

ProfileAssetName

Name of default ScriptableObject instance asset to create. Value is "Default" concatenated with ProfileName

ProfileFolderObject

Unity object pointing to folder asset to place ScriptableObject profile class file, if applicable

ProfileInstance

Object instance of ScriptableObject profile class for extension service created

ProfileName

Name of ScriptableObject profile class to create. Value is ServiceName concatenated with "Profile"

Result

Current result of extension service file(s) create operation

SampleCode

Sample code string demonstrating example usage for new Extension service created

ServiceFolderObject

Unity object pointing to folder asset to place Service class file

ServiceName

The name of the new extension service to build

ServiceType

System.Type of Extension Service created

Stage

Current stage in UI workflow for creation

UsesInspector

Should a custom editor inspector class be created for new extension service

UsesProfile

Should a ScriptableObject profile class be created for new extension service

Methods

BeginAssetCreationProcess()

Start the creation process for all relevant extension service files based on current creator property settings

CanBuildAsset(Object, String)

Returns true if the asset supplied, via Folder object representing path and file name string (assuming .cs files only), does not exist. False otherwise

IsValidFolder(Object)

Returns true if the folder path supplied by Folder object is a valid location in the Unity project, false otherwise

IsValidFolder(String)

Returns true if the folder path string supplied is a valid location in the Unity project, false otherwise

LoadStoredState()

Load creator state from unity SessionState

ResetState()

Reset current creator state to default and save

SetAllFolders(String)
StoreState()

Save current creator state to session registry in Unity

ValidateAssets(List<String>)

Validate template assets

ValidateName(List<String>)

Return true if configured Extension Service class name is valid. False otherwise

ValidateNamespace(List<String>)

Validate namespace property with each class/interface file to be created for new extension service

ValidatePlatforms(List<String>)

Validate that SupportedPlatforms is not zero.

Applies to