Gorgon
Show / Hide Table of Contents

Class GorgonStateBuilderCommon<TB, TRs>

Common functionality for the a state fluent builder.

Inheritance
object
GorgonStateBuilderCommon<TB, TRs>
GorgonSamplerStateBuilder
GorgonStateBuilderAllocator<TB, TRs>
Implements
IGorgonFluentBuilder<TB, TRs>
Inherited Members
object.ToString()
object.Equals(object)
object.Equals(object, object)
object.ReferenceEquals(object, object)
object.GetHashCode()
object.GetType()
object.MemberwiseClone()
Namespace: Gorgon.Graphics.Core
Assembly: Gorgon.Graphics.Core.dll
Syntax
public abstract class GorgonStateBuilderCommon<TB, TRs> : IGorgonFluentBuilder<TB, TRs> where TB : GorgonStateBuilderCommon<TB, TRs> where TRs : class
Type Parameters
Name Description
TB

The type of builder.

TRs

The type of state.

Properties

| Edit this page View Source

WorkingState

Property to set or return the state being edited.

Declaration
protected TRs WorkingState { get; }
Property Value
Type Description
TRs

Methods

| Edit this page View Source

Build()

Function to return the state.

Declaration
public TRs Build()
Returns
Type Description
TRs

The state created or updated by this builder.

| Edit this page View Source

Clear()

Function to clear the builder to a default state.

Declaration
public TB Clear()
Returns
Type Description
TB

The fluent builder interface.

| Edit this page View Source

OnClearState()

Function to clear the working state for the builder.

Declaration
protected abstract TB OnClearState()
Returns
Type Description
TB

The fluent builder interface.

| Edit this page View Source

OnCreateState()

Function to create a new state with the properties copied from the working copy.

Declaration
protected abstract TRs OnCreateState()
Returns
Type Description
TRs

The new render state.

| Edit this page View Source

OnResetTo(TRs)

Function to reset the builder to the specified state.

Declaration
protected abstract TB OnResetTo(TRs state)
Parameters
Type Name Description
TRs state

The state to copy from.

Returns
Type Description
TB

The fluent builder interface.

| Edit this page View Source

ResetTo(TRs)

Function to reset the builder to the specified state.

Declaration
public TB ResetTo(TRs state = null)
Parameters
Type Name Description
TRs state

[Optional] The specified state to copy.

Returns
Type Description
TB

The fluent builder interface.

Implements

IGorgonFluentBuilder<TB, TBo>

Extension Methods

GorgonDebugExtensions.ValidateObject<T>(T, string)
GorgonNullExtensions.AsNullable<T>(object)
GorgonNullExtensions.IfNull<T>(object, T)
GorgonNullExtensions.IsNull(object)
  • Edit this page
  • View Source
In this article
Back to top Copyright 2023 - Licensed under the MIT license by Michael Winsor (Tape_Worm).
Send comments on this topic to the author