[ create a new paste ] login | about

Link: http://codepad.org/xosBhZCK    [ raw code | fork ]

Plain Text, pasted on Jan 3:
using System.IO;

namespace Foo
{
	public class Data
	{
		public String name = null;
		public int value = 0;
	}

	public class SaveData 
	{
		
		public SaveData() { }
		
		public void save(String path, Data foo)
		{
			StreamWriter sw;
			using( sw = new StreamWriter(path) )
			{
				sw.WriteLine( String.Format("name={0}", foo.name) );
				sw.WriteLine( String.Format("value={0}", foo.value) );
			}
			
			// セーブしました、のメッセージを
		}
		
	}

}



Create a new paste based on this one


Comments: