NBody.NBody.GetResource C# (CSharp) Method

GetResource() public static method

public static GetResource ( string fullname ) : byte[]
fullname string
return byte[]
        public static byte[] GetResource(string fullname)
        {
            Assembly asm = Assembly.GetExecutingAssembly();

            using (Stream s = asm.GetManifestResourceStream(fullname))
            {
                using (StreamReader r = new StreamReader(s))
                {
                    return System.Text.Encoding.ASCII.GetBytes(r.ReadToEnd());
                }
            }
        }