2012-03-19 23:57:59 +00:00
|
|
|
|
using System;
|
|
|
|
|
using System.IO;
|
|
|
|
|
using Axios.Engine.Interfaces;
|
2012-03-24 23:06:51 +00:00
|
|
|
|
using Microsoft.Xna.Framework;
|
2012-03-19 23:57:59 +00:00
|
|
|
|
|
|
|
|
|
namespace Axios.Engine.File
|
|
|
|
|
{
|
|
|
|
|
public class AxiosTitleFile : AxiosFile, IAxiosFile
|
|
|
|
|
{
|
|
|
|
|
public AxiosTitleFile(string filename)
|
|
|
|
|
{
|
|
|
|
|
//Title Files can only be opened for reading!
|
|
|
|
|
|
|
|
|
|
this._filename = filename;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public override void WriteData(string data, FileMode mode)
|
|
|
|
|
{
|
|
|
|
|
throw new NotImplementedException();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public override string ReadData()
|
|
|
|
|
{
|
|
|
|
|
StreamReader sr = new StreamReader(TitleContainer.OpenStream(_filename));
|
|
|
|
|
this.Content = sr.ReadToEnd();
|
|
|
|
|
sr.Close();
|
|
|
|
|
return this.Content;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|