public ISigo Set1(string key, ISigo value) { switch (value.Flags & Bits.CPLMR) { case Bits.MR: return(this); case Bits.LMR: return(Sigo.Create(Bits.LMR)); default: return(Sigo.Create(Bits.LMR).Set1(key, value)); } }
private ISigo Delete(int rf, string key) { rf = Bits.CountDown(rf); if (Bits.IsEmpty(rf)) { return(Sigo.Create(Bits.Proton(rf))); } if (Bits.IsFrozen(rf)) { return(new SigoTree(Bits.RemoveFrozen(rf), DictCloneRemove(key))); } else { Flags = rf; DictRemove(key); return(this); } }
private ISigo SetFlags(int rf) { if (rf == Flags) { return(this); } if (Bits.IsEmpty(rf)) { return(Sigo.Create(Bits.Proton(rf))); } if (Bits.IsFrozen(rf)) { return(new SigoTree(Bits.RemoveFrozen(rf), DictClone())); } else { Flags = rf; return(this); } }
public ISigo Get1(string key) { Paths.CheckKey(key); return(TryGetValue(key, out var value) ? value : Sigo.Create(Bits.Def(Flags))); }
public override int GetHashCode() { return(Sigo.GetHashCode(this)); }
public override bool Equals(object obj) { return(obj is ISigo other && Sigo.Equals(this, other)); }
public bool Equals(ISigo other) { return(Sigo.Equals(this, other)); }
public ISigo Get1(string key) { Paths.CheckKey(key); return(Sigo.Create(Bits.MR)); }