BACnet.Client.Descriptors.DescriptorRegistrar._getRegistration C# (CSharp) Method

_getRegistration() private method

Retrieves a suitable registration for an object
private _getRegistration ( ushort vendorId, ushort objectType ) : Registration
vendorId ushort The vendor id of the object
objectType ushort The object type of the object
return Registration
        private Registration _getRegistration(ushort vendorId, ushort objectType)
        {
            Registration ret;
            uint key;

            key = _getKey(vendorId, objectType);
            if (_registrations.TryGetValue(key, out ret))
                return ret;

            key = _getKey(0, objectType);
            if (_registrations.TryGetValue(key, out ret))
                return ret;

            return _defaultRegistration;
        }