RSPersistRuleTableData ICopyCloneable <RSPersistRuleTableData> .Clone() { RSPersistRuleTableData clone = new RSPersistRuleTableData(); Rules = CloneUtils.Clone(clone.Rules); return(clone); }
public object Clone() { var cl = (DataRecord)MemberwiseClone(); cl.data = (Dictionary <string, object>)CloneUtils.deepClone(data); return(cl); }
public object Clone() { var copy = (CorrectSuperComplexClass)MemberwiseClone(); copy.objectField = (CorrectComplexClass)CloneUtils.deepClone(objectField); return(copy); }
public void CopyFrom(RSRuleTableData inTable) { Id = inTable.Id; Name = inTable.Name; Rules = CloneUtils.DeepClone(inTable.Rules); UniqueTriggers = CloneUtils.Clone(inTable.UniqueTriggers); }
public void CopyFrom(RSResolvableValueData inValue) { Mode = inValue.Mode; Value = inValue.Value; Query = inValue.Query; QueryArguments = CloneUtils.Clone(inValue.QueryArguments); Register = inValue.Register; }
public object Clone() { var cl = (Data)MemberwiseClone(); cl.preview = (byte[])CloneUtils.deepClone(preview); cl.data = (byte[])CloneUtils.deepClone(data); return(cl); }
public void CopyFrom(RSPersistEntityData inClone) { EntityId = inClone.EntityId; Active = inClone.Active; CloneUtils.CopyFrom(ref ComponentData, inClone.ComponentData); CloneUtils.CopyFrom(ref TableData, inClone.TableData); CloneUtils.CopyFrom(ref CustomData, inClone.CustomData); }
private static HashSet <String> copyRecord(DataRecord source, DataRecord target, bool copyReadOnlyFields, bool copyNonReplicatableFields, ICollection <String> fields) { var errors = new HashSet <String>(); foreach (var tgtFf in target.getFormat()) { var fieldName = tgtFf.getName(); var srcFf = source.getFormat().getFieldFormat(fieldName); if (fields != null && !fields.Contains(tgtFf.getName())) { continue; } if (srcFf == null) { continue; } if (tgtFf.isReadonly() && !copyReadOnlyFields) { continue; } if (!copyNonReplicatableFields) { if (tgtFf.isNotReplicated() || srcFf.isNotReplicated()) { continue; } } try { if (srcFf.getFieldWrappedClass().Equals(tgtFf.getFieldWrappedClass())) { target.setValue(fieldName, CloneUtils.genericClone(source.getValue(fieldName))); } else { target.setValue(fieldName, tgtFf.valueFromString(srcFf.valueToString(source.getValue(fieldName)))); } } catch (Exception ex2) { var msg = String.Format(Cres.get().getString("dtErrCopyingField"), fieldName); Logger.getLogger(Log.DATATABLE).debug(msg, ex2); errors.Add(msg + ": " + ex2.Message); continue; } } return(errors); }
RSPersistComponentData ICopyCloneable <RSPersistComponentData> .Clone() { RSPersistComponentData clone = new RSPersistComponentData(); clone.ComponentType = ComponentType; clone.NamedValues = CloneUtils.Clone(NamedValues); clone.CustomData = CloneUtils.Clone(CustomData); return(clone); }
public RSActionData Clone() { RSActionData clone = new RSActionData(); clone.Enabled = Enabled; clone.Action = Action; clone.Arguments = CloneUtils.DeepClone(Arguments); return(clone); }
public override object Clone() { TaxBaseSolidaryArticle cloneArticle = (TaxBaseSolidaryArticle)this.MemberwiseClone(); cloneArticle.InternalConfig = CloneUtils<IArticleConfigFeatures>.CloneOrNull(this.InternalConfig); cloneArticle.InternalRole = this.InternalRole; cloneArticle.InternalEvaluate = this.InternalEvaluate; return cloneArticle; }
public RSRuleTableData Clone() { RSRuleTableData data = new RSRuleTableData(); data.Id = Id; data.Name = Name; data.Rules = CloneUtils.DeepClone(Rules); data.UniqueTriggers = CloneUtils.Clone(UniqueTriggers); return(data); }
public ArticleConfigMaster(ConfigRole _role, ConfigName _name, ConfigStub _stub, params ConfigRole[] _path) { InternalRole = _role; InternalName = _name; InternalPath = _path.ToList(); InternalStub = CloneUtils <ConfigStub> .CloneOrNull(_stub); }
public object Clone() { ArticleGeneralResult cloneResult = (ArticleGeneralResult)this.MemberwiseClone(); cloneResult.InternalConfig = CloneUtils <ConfigProp> .CloneOrNull(InternalConfig); cloneResult.ResultValues = CloneUtils <ResultValuesStore> .CloneOrNull(ResultValues); return(cloneResult); }
public void SetSymbolRole(ConfigRole _role, ConfigName _name, ConfigStub _stub, params ConfigRole[] _path) { InternalRole = _role; InternalName = _name; InternalPath = _path.ToList(); InternalStub = CloneUtils <ConfigStub> .CloneOrNull(_stub); }
/// <exception cref="Sharpen.CloneNotSupportedException"></exception> public override object Clone() { Apache.Http.Client.Methods.HttpEntityEnclosingRequestBase clone = (Apache.Http.Client.Methods.HttpEntityEnclosingRequestBase )base.Clone(); if (this.entity != null) { clone.entity = CloneUtils.CloneObject(this.entity); } return(clone); }
public ConfigStub CloneMasterStub(ConfigCode _code, ConfigRole _role, ConfigGang _gang, ConfigType _type, ConfigBind _bind, TaxingBehaviour _taxing, HealthBehaviour _health, SocialBehaviour _social) { ConfigStub returnStub = CloneUtils <ConfigStub> .CloneOrNull(InternalStub); returnStub.SetSourceConfig(_code, _role, _gang, _type, _bind, _taxing, _health, _social); return(returnStub); }
public virtual object Clone() { GeneralArticle cloneArticle = (GeneralArticle)this.MemberwiseClone(); cloneArticle.InternalConfig = CloneUtils <IArticleConfigFeatures> .CloneOrNull(this.InternalConfig); cloneArticle.InternalRole = this.InternalRole; return(cloneArticle); }
public RSResolvableValueData Clone() { RSResolvableValueData clone = new RSResolvableValueData(); clone.Mode = Mode; clone.Value = Value; clone.Query = Query; clone.QueryArguments = CloneUtils.Clone(QueryArguments); clone.Register = Register; return(clone); }
public virtual object Clone() { ArticleConfigMaster cloneMaster = (ArticleConfigMaster)this.MemberwiseClone(); cloneMaster.InternalRole = this.InternalRole; cloneMaster.InternalName = this.InternalName; cloneMaster.InternalPath = this.InternalPath.ToList(); cloneMaster.InternalStub = CloneUtils <ConfigStub> .CloneOrNull(this.InternalStub); return(cloneMaster); }
public override object Clone() { ContractTimesheetArticle cloneArticle = (ContractTimesheetArticle)this.MemberwiseClone(); cloneArticle.InternalConfig = CloneUtils <IArticleConfigFeatures> .CloneOrNull(this.InternalConfig); cloneArticle.InternalRole = this.InternalRole; cloneArticle.InternalEvaluate = this.InternalEvaluate; return(cloneArticle); }
/// <exception cref="Sharpen.CloneNotSupportedException"></exception> public virtual object Clone() { Apache.Http.Client.Methods.AbstractExecutionAwareRequest clone = (Apache.Http.Client.Methods.AbstractExecutionAwareRequest )base.Clone(); clone.headergroup = CloneUtils.CloneObject(this.headergroup); clone.@params = CloneUtils.CloneObject(this.@params); clone.abortLock = new ReentrantLock(); clone.cancellable = null; clone.aborted = false; return(clone); }
public void CopyFrom(RSRuleData inRule) { Name = inRule.Name; RoutineGroup = inRule.RoutineGroup; Enabled = inRule.Enabled; OnlyOnce = inRule.OnlyOnce; TriggerId = inRule.TriggerId; Conditions = CloneUtils.DeepClone(inRule.Conditions); ConditionSubset = inRule.ConditionSubset; Actions = CloneUtils.DeepClone(inRule.Actions); }
public void TestCorrectComplexClass() { var obj1 = new CorrectComplexClass(101, "abc"); var obj2 = (CorrectComplexClass)CloneUtils.genericClone(obj1); AssertAreEqualButNotSame(obj1, obj2); AssertAreEqualButNotSame(obj1.objectField, obj2.objectField); obj1.objectField.intValue = 303; Assert.AreEqual(101, obj2.objectField.intValue); }
public RSPersistEntityData Clone() { RSPersistEntityData clone = new RSPersistEntityData(); clone.EntityId = EntityId; clone.Active = Active; clone.ComponentData = CloneUtils.DeepClone(ComponentData); clone.TableData = CloneUtils.Clone(TableData); clone.CustomData = CloneUtils.Clone(CustomData); return(clone); }
public override object Clone() { PositionTermArticle cloneArticle = (PositionTermArticle)this.MemberwiseClone(); cloneArticle.InternalConfig = CloneUtils <IArticleConfigFeatures> .CloneOrNull(this.InternalConfig); cloneArticle.InternalRole = this.InternalRole; cloneArticle.InternalEvaluate = this.InternalEvaluate; return(cloneArticle); }
public override object Clone() { InsBaseHealthCompoundArticle cloneArticle = (InsBaseHealthCompoundArticle)this.MemberwiseClone(); cloneArticle.InternalConfig = CloneUtils <IArticleConfigFeatures> .CloneOrNull(this.InternalConfig); cloneArticle.InternalRole = this.InternalRole; cloneArticle.InternalEvaluate = this.InternalEvaluate; return(cloneArticle); }
public override object Clone() { TaxIncomesWithholdPartnerArticle cloneArticle = (TaxIncomesWithholdPartnerArticle)this.MemberwiseClone(); cloneArticle.InternalConfig = CloneUtils <IArticleConfigFeatures> .CloneOrNull(this.InternalConfig); cloneArticle.InternalRole = this.InternalRole; cloneArticle.InternalEvaluate = this.InternalEvaluate; return(cloneArticle); }
public void TestList() { var l1 = new List <CorrectSuperComplexClass> { new CorrectSuperComplexClass(101, "abc"), new CorrectSuperComplexClass(202, "def") }; var l2 = (List <CorrectSuperComplexClass>)CloneUtils.genericClone(l1); Assert.AreNotSame(l1, l2); AssertAreEqualButNotSame(l1[0], l2[0]); AssertAreEqualButNotSame(l1[1], l2[1]); }
public void TestStruct() { var struct1 = new SimpleStruct(101, "abc"); var struct2 = (SimpleStruct)CloneUtils.genericClone(struct1); AssertAreEqualButNotSame(struct1, struct2); struct1.intValue = 303; Assert.AreEqual(101, struct2.intValue); Assert.AreEqual("abc", struct1.stringValue); struct2.stringValue = "def"; Assert.AreEqual("abc", struct1.stringValue); }