Class EntityCopyOptionsBuilder
Default implementation of IEntityCopyOptionsBuilder.
Inheritance
Implements
Namespace: StylelabsStylelabs.MSdkStylelabs.M.Sdk.ModelsContent
Assembly: Stylelabs.M.Sdk.dll
Syntax
public class EntityCopyOptionsBuilder : IEntityCopyOptionsBuilderConstructors
EntityCopyOptionsBuilder()
Initializes a new instance of the EntityCopyOptionsBuilder class.
Declaration
public EntityCopyOptionsBuilder()EntityCopyOptionsBuilder(IEntityCopyOptions)
Initializes a new instance of the EntityCopyOptionsBuilder class.
Declaration
public EntityCopyOptionsBuilder(IEntityCopyOptions copyOptions)Parameters
| Type | Name | Description |
|---|---|---|
| IEntityCopyOptions | copyOptions |
The IEntityCopyOptions. |
Methods
Build()
Gets the resulting instance of IEntityCopyOptions.
Declaration
public IEntityCopyOptions Build()Returns
| Type | Description |
|---|---|
| IEntityCopyOptions |
The builder. |
WithCopyProfile(long)
Indicates that the entity should be copied using the copy profile with the specified id.
Declaration
public IEntityCopyOptionsBuilder WithCopyProfile(long id)Parameters
| Type | Name | Description |
|---|---|---|
| long | id |
The id of the copy profile. |
Returns
| Type | Description |
|---|---|
| IEntityCopyOptionsBuilder |
The builder. |
WithCopyProfile(string)
Indicates that the entity should be copied using the copy profile with the specified identifier.
Declaration
public IEntityCopyOptionsBuilder WithCopyProfile(string identifier)Parameters
| Type | Name | Description |
|---|---|---|
| string | identifier |
The identifier of the copy profile. |
Returns
| Type | Description |
|---|---|
| IEntityCopyOptionsBuilder |
The builder. |
WithDestinationEntityId(long)
Indicates that the entity should be copied to the entity with the specified id.
Declaration
public IEntityCopyOptionsBuilder WithDestinationEntityId(long id)Parameters
| Type | Name | Description |
|---|---|---|
| long | id |
The destination entity id. |
Returns
| Type | Description |
|---|---|
| IEntityCopyOptionsBuilder |
The builder. |
WithProperties(IEnumerable<IPropertyCopyOption>)
Indicates that the entity should be copied with the specified properties.
Declaration
public IEntityCopyOptionsBuilder WithProperties(IEnumerable<IPropertyCopyOption> properties)Parameters
| Type | Name | Description |
|---|---|---|
| IEnumerable<>IPropertyCopyOption | properties |
The properties collection. |
Returns
| Type | Description |
|---|---|
| IEntityCopyOptionsBuilder |
The builder. |
WithProperty(string, PropertyCopyMethod, string)
Indicates that the entity should be copied with the specified property.
Declaration
public IEntityCopyOptionsBuilder WithProperty(string property, PropertyCopyMethod method, string newValue = null)Parameters
| Type | Name | Description |
|---|---|---|
| string | property |
The name of the property. |
| PropertyCopyMethod | method |
The copy method. |
| string | newValue |
The property new value. |
Returns
| Type | Description |
|---|---|
| IEntityCopyOptionsBuilder |
The builder. |
WithRelation(string, RelationCopyMethod, IEntityCopyOptions)
Indicates that the entity should be copied with the specified relation.
Declaration
public IEntityCopyOptionsBuilder WithRelation(string relation, RelationCopyMethod method, IEntityCopyOptions relatedOptions = null)Parameters
| Type | Name | Description |
|---|---|---|
| string | relation |
The name of the relation. |
| RelationCopyMethod | method |
The copy method. |
| IEntityCopyOptions | relatedOptions |
The related options. |
Returns
| Type | Description |
|---|---|
| IEntityCopyOptionsBuilder |
The builder. |
WithRelations(IEnumerable<IRelationCopyOption>)
Indicates that the entity should be copied with the specified relations.
Declaration
public IEntityCopyOptionsBuilder WithRelations(IEnumerable<IRelationCopyOption> relations)Parameters
| Type | Name | Description |
|---|---|---|
| IEnumerable<>IRelationCopyOption | relations |
The relations collection. |
Returns
| Type | Description |
|---|---|
| IEntityCopyOptionsBuilder |
The builder. |