public int CompareTo(CatalogKey other) { if (other == null) { throw new ArgumentNullException(nameof(other)); } if (NodeId != other.NodeId) { return(NodeId < other.NodeId ? -1 : 1); } return(HfsPlusUtilities.FastUnicodeCompare(Name, other.Name)); }
public int CompareTo(AttributeKey other) { if (other == null) { throw new ArgumentNullException("other"); } if (_fileId != other._fileId) { return(_fileId < other._fileId ? -1 : 1); } return(HfsPlusUtilities.FastUnicodeCompare(_name, other._name)); }
public override int CompareTo(BTreeKey other) { var attributeKey = other as AttributeKey; if (attributeKey == null) { throw new ArgumentNullException(nameof(other)); } if (this.FileId != attributeKey.FileId) { return(this.FileId < attributeKey.FileId ? -1 : 1); } return(HfsPlusUtilities.FastUnicodeCompare(this.Name, attributeKey.Name)); }