getParameter

fun <T> getParameter(parameterName: String, clazz: Class<T>): T

Gets the value of a parameter by its name and type.

Return

The value of the parameter of the specified name and type.

Parameters

T

The type of the parameter to retrieve. Supported types include: Integer, Boolean, Float, Color3, Color4, Vector2, Vector3, Vector4, Matrix3, Matrix4, TextureResource.

parameterName

The name of the parameter to retrieve.

clazz

The class of the parameter type.

Throws

IllegalStateException

If this material is closed or invalid.

IllegalArgumentException

If the specified parameter type is not supported.


inline fun <T> getParameter(parameterName: String): T

Gets the value of a parameter by its name and type.

Return

The value of the parameter of the specified name and type.

Parameters

T

The type of the parameter to retrieve. Supported types include: Integer, Boolean, Float, Color3, Color4, Vector2, Vector3, Vector4, Matrix3, Matrix4, TextureResource.

parameterName

The name of the parameter to retrieve.

Throws

IllegalStateException

If this material is closed or invalid.

IllegalArgumentException

If the specified parameter type is not supported.