Class BuildTargetBase
Build target base class
Namespace: Unity.Industrial.Forma.Editor.UI.Components
Syntax
[MovedFrom(true, "UnityEditor.Industrial.Configuring.UI", "Unity.Industrial.Configurator.Editor", null)]
public abstract class BuildTargetBase : IBuildTarget
Fields
m_BuildProfile
Current build profile. Must be initialized before calling methods.
Declaration
protected BuildProfile m_BuildProfile
Field Value
Type | Description |
---|---|
BuildProfile |
Properties
DisplayName
Display name
Declaration
public virtual string DisplayName { get; }
Property Value
Type | Description |
---|---|
String |
Implements
isBuildTargetActive
Is build target active
Declaration
protected bool isBuildTargetActive { get; }
Property Value
Type | Description |
---|---|
Boolean |
SupportedBuildTarget
Supported build target
Declaration
public virtual SupportedBuildTarget SupportedBuildTarget { get; }
Property Value
Type | Description |
---|---|
SupportedBuildTarget |
Implements
Methods
AddButtons(VisualElement)
Add buttons
Declaration
public virtual void AddButtons(VisualElement buttonContainer)
Parameters
Type | Name | Description |
---|---|---|
VisualElement | buttonContainer |
Implements
Exceptions
Type | Condition |
---|---|
InvalidOperationException |
AddSettings(VisualElement)
Add settings
Declaration
public virtual void AddSettings(VisualElement settings)
Parameters
Type | Name | Description |
---|---|---|
VisualElement | settings |
Implements
Exceptions
Type | Condition |
---|---|
InvalidOperationException |
BuildAsync(Boolean)
Build
Declaration
protected async Task<bool> BuildAsync(bool buildAndRun)
Parameters
Type | Name | Description |
---|---|---|
Boolean | buildAndRun |
Returns
Type | Description |
---|---|
Task<Boolean> |
BuildAsync(IDictionary<String, String>)
Build
Declaration
public virtual async Task<bool> BuildAsync(IDictionary<string, string> configData)
Parameters
Type | Name | Description |
---|---|---|
IDictionary<String, String> | configData |
Returns
Type | Description |
---|---|
Task<Boolean> |
Implements
CreateBuildAndLaunchButton()
Create build and launch button
Declaration
protected VisualElement CreateBuildAndLaunchButton()
Returns
Type | Description |
---|---|
VisualElement |
CreateExportButton(Action)
Create export button
Declaration
protected VisualElement CreateExportButton(Action action)
Parameters
Type | Name | Description |
---|---|---|
Action | action |
Returns
Type | Description |
---|---|
VisualElement |
CreateLaunchButton(String, Action, Boolean)
Create and launch button
Declaration
protected VisualElement CreateLaunchButton(string label, Action action, bool isEnabled)
Parameters
Type | Name | Description |
---|---|---|
String | label | |
Action | action | |
Boolean | isEnabled |
Returns
Type | Description |
---|---|
VisualElement |
GetBuildActionsAsync()
Get build actions
Declaration
public virtual async Task<IEnumerable<BuildAction>> GetBuildActionsAsync()
Returns
Type | Description |
---|---|
Task<IEnumerable<BuildAction>> |
Implements
Exceptions
Type | Condition |
---|---|
InvalidOperationException |
Initialize(BuildProfile)
Initialize
Declaration
public void Initialize(BuildProfile buildProfile)
Parameters
Type | Name | Description |
---|---|---|
BuildProfile | buildProfile |
Implements
IsAtLeastOneProductPublisherActiveAsync()
Is at least one product publisher active and ready to publish
Declaration
public async Task<bool> IsAtLeastOneProductPublisherActiveAsync()
Returns
Type | Description |
---|---|
Task<Boolean> | True if there is at least one product publisher |
IsAtLeastOneRuntimePublisherActiveAsync()
Is at least one runtime publisher active and ready to publish
Declaration
public async Task<bool> IsAtLeastOneRuntimePublisherActiveAsync()
Returns
Type | Description |
---|---|
Task<Boolean> | True if there is at least one active publisher |
IsLastBuildPathValid()
Is last build path valid?
Declaration
protected bool IsLastBuildPathValid()
Returns
Type | Description |
---|---|
Boolean |
PublishProductsAsync(Boolean, Boolean)
Publish products using product publishers.
Declaration
public async Task<bool> PublishProductsAsync(bool displayDialogue = true, bool showLogs = false)
Parameters
Type | Name | Description |
---|---|---|
Boolean | displayDialogue | Whether or not a prompt should show asking user to confirm whether or not they wish to publish |
Boolean | showLogs | Whether or not information regarding publish process should be printed to the console |
Returns
Type | Description |
---|---|
Task<Boolean> | True if operation was successful. False otherwise. |
Implements
PublishRuntimeAsync(Boolean, Boolean)
Publish runtime using runtime publishers.
Declaration
public async Task<bool> PublishRuntimeAsync(bool displayDialogue = true, bool showLogs = false)
Parameters
Type | Name | Description |
---|---|---|
Boolean | displayDialogue | Whether or not a prompt should show asking user to confirm whether or not they wish to publish |
Boolean | showLogs | Whether or not information regarding publish process should be printed to the console |
Returns
Type | Description |
---|---|
Task<Boolean> | True if operation was successful. False otherwise. |
Implements
SwitchPlatform()
Switch platform
Declaration
protected void SwitchPlatform()