コード例 #1
0
        /// <summary>
        ///
        /// </summary>
        /// <param name="wrapper"></param>
        /// <param name="pfd"></param>
        /// <param name="withdesc">true, if you want to include the Description of the DAta stored in the passed Wrapper</param>
        /// <returns></returns>
        public static string Serialize(SimPe.Interfaces.Plugin.Internal.IPackedFileName wrapper, SimPe.Interfaces.Files.IPackedFileDescriptorBasic pfd, bool withdesc)
        {
            string s = Formater.SerializeTGI(wrapper, pfd);

            if (withdesc)
            {
                if (wrapper != null)
                {
                    s += wrapper.Description;
                }
                s += Seperator;
            }

            return(s);
        }
コード例 #2
0
        public static string SerializeTypeHeader(SimPe.Interfaces.Plugin.Internal.IPackedFileName wrapper, SimPe.Interfaces.Files.IPackedFileDescriptorBasic pfd, bool withdesc)
        {
            string s = "";

            s += Formater.SerializeTGIHeader();

            if (withdesc && wrapper != null)
            {
                s += wrapper.DescriptionHeader;
            }
            return(s);
        }
コード例 #3
0
 public static string Serialize(SimPe.Interfaces.Plugin.Internal.IPackedFileName wrapper, SimPe.Interfaces.Files.IPackedFileDescriptorBasic pfd)
 {
     return(Serialize(wrapper, pfd, false));
 }
コード例 #4
0
        public virtual string SerializeTGI(SimPe.Interfaces.Plugin.Internal.IPackedFileName wrapper, SimPe.Interfaces.Files.IPackedFileDescriptorBasic pfd)
        {
            string s = "";

            if (wrapper != null)
            {
                s += SaveStr(wrapper.ResourceName) + Seperator;
            }
            else
            {
                s += SaveStr(pfd.TypeName.ToString()) + Seperator;
            }

            s += "0x" + Helper.HexString(pfd.Type) + Seperator;
            s += "0x" + Helper.HexString(pfd.Group) + Seperator;
            s += "0x" + Helper.HexString(pfd.SubType) + Seperator;
            s += "0x" + Helper.HexString(pfd.Instance) + Seperator;

            return(s);
        }