OpenMetaverse.InventoryManager.StringToInventoryType C# (CSharp) Method

StringToInventoryType() public static method

Convert a string into a valid InventoryType
public static StringToInventoryType ( string type ) : InventoryType
type string A string representation of the InventoryType to convert
return InventoryType
        public static InventoryType StringToInventoryType(string type)
        {
            for (int i = 0; i < _InventoryTypeNames.Length; i++)
            {
                if (_InventoryTypeNames[i] == type)
                    return (InventoryType)i;
            }

            return InventoryType.Unknown;
        }