1. FluentEntity

Class FluentEntity

Defines the fluent entity type.

Inheritance
object
FluentEntity
Namespace: StylelabsStylelabs.MSdkFluentModels
Assembly: Stylelabs.M.Sdk.Fluent.dll
Syntax
public class FluentEntity

Constructors

FluentEntity(IEntity, IEntitiesClient, IEntityLoadConfiguration)

Initializes a new instance of the FluentEntity class.

Declaration
public FluentEntity(IEntity entity, IEntitiesClient entities, IEntityLoadConfiguration entityLoadConfiguration = null)
Parameters
TypeNameDescription
IEntityentity

The entity.

IEntitiesCliententities

The entities.

IEntityLoadConfigurationentityLoadConfiguration

The load configuration.

Properties

Cultures

Declaration
public IReadOnlyList<CultureInfo> Cultures { get; }
Property Value
TypeDescription
IReadOnlyList<>CultureInfo

DefinitionName

Declaration
public string DefinitionName { get; }
Property Value
TypeDescription
string

Id

Declaration
public long? Id { get; }
Property Value
TypeDescription
long

Identifier

Declaration
public string Identifier { get; set; }
Property Value
TypeDescription
string

InheritsSecurity

Declaration
public bool InheritsSecurity { get; set; }
Property Value
TypeDescription
bool

IsNew

Declaration
public bool IsNew { get; }
Property Value
TypeDescription
bool

IsPathRoot

Declaration
public bool IsPathRoot { get; set; }
Property Value
TypeDescription
bool

IsSystemOwned

Declaration
public bool IsSystemOwned { get; set; }
Property Value
TypeDescription
bool

this[string, CultureInfo]

Gets the property value in the specified culture.

Declaration
public object this[string name, CultureInfo cultureInfo] { get; set; }
Parameters
TypeNameDescription
stringname

The property name.

CultureInfocultureInfo

The culture info.

Property Value
TypeDescription
object

this[string]

Gets the property value.

Declaration
public object this[string name] { get; set; }
Parameters
TypeNameDescription
stringname

The property name.

Property Value
TypeDescription
object

LockedBy

Declaration
public long? LockedBy { get; }
Property Value
TypeDescription
long

LockedOn

Declaration
public DateTime? LockedOn { get; }
Property Value
TypeDescription
DateTime

Object

Gets or sets the IEntity.

Declaration
public IEntity Object { get; set; }
Property Value
TypeDescription
IEntity

Version

Declaration
public long Version { get; }
Property Value
TypeDescription
long

Methods

Child(string, Action<IParentToOneChildRelation>)

Declaration
public FluentEntity Child(string relationName, Action<IParentToOneChildRelation> relationDelegate)
Parameters
TypeNameDescription
stringrelationName
Action<>IParentToOneChildRelationrelationDelegate
Returns
TypeDescription
FluentEntity

Children(string, Action<IParentToManyChildrenRelation>)

Declaration
public FluentEntity Children(string relationName, Action<IParentToManyChildrenRelation> relationDelegate)
Parameters
TypeNameDescription
stringrelationName
Action<>IParentToManyChildrenRelationrelationDelegate
Returns
TypeDescription
FluentEntity

Delete()

Declaration
public void Delete()

GetPropertyValue<T>(string, Action<T>)

Declaration
public FluentEntity GetPropertyValue<T>(string name, Action<T> propertyValueAccessor)
Parameters
TypeNameDescription
stringname
Action<>propertyValueAccessor
Returns
TypeDescription
FluentEntity
Type Parameters
NameDescription
T

GetPropertyValue<T>(string, CultureInfo, Action<T>)

Declaration
public FluentEntity GetPropertyValue<T>(string name, CultureInfo culture, Action<T> propertyValueAccessor)
Parameters
TypeNameDescription
stringname
CultureInfoculture
Action<>propertyValueAccessor
Returns
TypeDescription
FluentEntity
Type Parameters
NameDescription
T

Parent(string, Action<IChildToOneParentRelation>)

Declaration
public FluentEntity Parent(string relationName, Action<IChildToOneParentRelation> relationDelegate)
Parameters
TypeNameDescription
stringrelationName
Action<>IChildToOneParentRelationrelationDelegate
Returns
TypeDescription
FluentEntity

Parents(string, Action<IChildToManyParentsRelation>)

Declaration
public FluentEntity Parents(string relationName, Action<IChildToManyParentsRelation> relationDelegate)
Parameters
TypeNameDescription
stringrelationName
Action<>IChildToManyParentsRelationrelationDelegate
Returns
TypeDescription
FluentEntity

Reload()

Declaration
public FluentEntity Reload()
Returns
TypeDescription
FluentEntity

Save()

Declaration
public FluentEntity Save()
Returns
TypeDescription
FluentEntity

SetPropertyValue(string, CultureInfo, object)

Declaration
public FluentEntity SetPropertyValue(string name, CultureInfo culture, object value)
Parameters
TypeNameDescription
stringname
CultureInfoculture
objectvalue
Returns
TypeDescription
FluentEntity

SetPropertyValue(string, object)

Declaration
public FluentEntity SetPropertyValue(string name, object value)
Parameters
TypeNameDescription
stringname
objectvalue
Returns
TypeDescription
FluentEntity

Extension Methods

If you have suggestions for improving this article, let us know!