BFSchema.CodeGenerators.CSharp.CSHelper.TypeMap C# (CSharp) Method

TypeMap() public static method

public static TypeMap ( IBfsType type ) : string
type IBfsType
return string
        public static string TypeMap(IBfsType type)
        {
            if (type is BfsNamedType)
                return (type as BfsNamedType).DataBlock.Name;

            if (type is BfsPrimitiveType)
            {
                string typeString = (type as BfsPrimitiveType).PrimitiveType.ToString();
                switch (typeString)
                {
                    case "Ubyte":
                        return "Byte";
                    case "Sbyte":
                        return "Byte";
                    default:
                        return typeString;
                }
            }
            else return "/* TODO!!! */";
        }