Esempio n. 1
0
            public static bool Decode(StringPiece slice, out DatabaseNameKey result)
            {
                KeyPrefix prefix;
                byte      typeByte;

                if (!KeyPrefix.Decode(slice, out prefix) || !slice.DecodeByte(out typeByte))
                {
                    result = default(DatabaseNameKey);
                    return(false);
                }

                result = new DatabaseNameKey();
                return(slice.DecodeStringWithLength(out result.Origin) && slice.DecodeStringWithLength(out result.DatabaseName));
            }
Esempio n. 2
0
            public static bool Decode(StringPiece slice, out ObjectStoreNamesKey result)
            {
                KeyPrefix prefix;
                byte      typeByte;

                if (!KeyPrefix.Decode(slice, out prefix) || !slice.DecodeByte(out typeByte))
                {
                    result = default(ObjectStoreNamesKey);
                    return(false);
                }

                result = new ObjectStoreNamesKey();
                return(slice.DecodeStringWithLength(out result._objectStoreName));
            }
Esempio n. 3
0
            public static bool Decode(StringPiece slice, out IndexNamesKey result)
            {
                KeyPrefix prefix;
                byte      typeByte;

                if (!KeyPrefix.Decode(slice, out prefix) || !slice.DecodeByte(out typeByte))
                {
                    result = default;
                    return(false);
                }

                result = new IndexNamesKey();
                return(slice.DecodeVarInt(out result.ObjectStoreId) && slice.DecodeStringWithLength(out result.IndexName));
            }