예제 #1
0
        public void GenerateBinaryData(VexObject vo, string path, out string filename)
        {
            string dataName = vo.Name + "Data";
            filename = path + dataName + ".dat";

            if (!Directory.Exists(path))
            {
                Directory.CreateDirectory(path);
            }

            FileStream stream = new FileStream(filename, FileMode.Create);
            VexDrawWriter writer = new VexDrawWriter(stream);

            DrawObject drawObject = new DrawObject(vo);
            writer.WriteDrawObject(drawObject);

            stream.Flush();

            //byte[] bytes = stream.ToArray();
            stream.Close();
        }
예제 #2
0
        public void GenerateBinaryData(VexObject vo, string path, out string filename)
        {
            string dataName = vo.Name + "Data";

            filename = path + dataName + ".dat";

            if (!Directory.Exists(path))
            {
                Directory.CreateDirectory(path);
            }

            FileStream    stream = new FileStream(filename, FileMode.Create);
            VexDrawWriter writer = new VexDrawWriter(stream);

            DrawObject drawObject = new DrawObject(vo);

            writer.WriteDrawObject(drawObject);

            stream.Flush();

            //byte[] bytes = stream.ToArray();
            stream.Close();
        }