Index: /trunk/MacFaceLibrary/FaceDef.cs
===================================================================
--- /trunk/MacFaceLibrary/FaceDef.cs	(revision 15)
+++ /trunk/MacFaceLibrary/FaceDef.cs	(revision 16)
@@ -11,4 +11,5 @@
 namespace MacFace
 {
+
 	/// <summary>
 	/// FaceDef ÌTvÌà¾Å·B
@@ -16,75 +17,44 @@
 	public class FaceDef
 	{
-		public static readonly string FaceDefName = "faceDef.plist";
-		public static readonly int PatternCols = 11;
-		public static readonly int PatternRows = 3;
+		public enum PatternSuite
+		{
+			Normal             = 0,
+			MemoryDecline      = 1,
+			MemoryInsufficient = 2
+		}
+
+		public enum MarkerBitMask
+		{
+			None    = 0x00,
+			PageIn  = 0x01,
+			PageOut = 0x02
+		}
+
+		private const string FaceDefName = "faceDef.plist";
+		private const int PatternCols = 11;
+		private const int PatternRows = 3;
 
 		private string _path    = "";
 		private string _title   = "";
-		private string _auther  = "";
+		private string _author  = "";
 		private string _version = ""; /*Version*/
 		private Uri    _webSite = null;
 
 		internal PartList _parts = new PartList();
-		//protected int[][,] patterns;
+		internal PartList[][] _patternSuites;
 		internal PartList _makers = new PartList();
-		internal FacePattern _patterns;
 
 
 		// ctor
-		public FaceDef() {}
-
-		// properties
-		public FacePattern FacePattern
-		{
-			get { return _patterns; }
-		}
-		public PartList Markers
-		{
-			get { return _makers; }
-		}
-		public PartList Parts
-		{
-			get { return _parts; }
-		}
-		public Uri WebSite
-		{
-			get { return _webSite; }
-			set { _webSite = value; }
-		}
-		public string /*Version*/ Version
-		{
-			get { return _version; }
-			set { _version = value; }
-		}
-		public string Author
-		{
-			get { return _auther; }
-			set { _auther = value; }
-		}
-		public string Title
-		{
-			get { return _title; }
-			set { _title = value; }
-		}
-		public string Path
-		{
-			get { return _path; }
-			set { _path = value; }
-		}
-
-		// methods
-		public static FaceDef CreateFaceDefFromFile(string path)
-		{
-			FaceDef faceDef = new FaceDef();
-
+		public FaceDef(string path)
+		{
 			string defFile = System.IO.Path.Combine(path, FaceDefName);
 			Hashtable def = PropertyList.Load(defFile);
 
 			// îñ
-			faceDef.Title = (def.ContainsKey("title") ? def["title"] as string : String.Empty);
-			faceDef.Author = (def.ContainsKey("author") ? def["author"] as string : String.Empty);
-			faceDef.Version = (def.ContainsKey("version") ? def["version"] as string : String.Empty);
-			faceDef.Path = path;
+			_path = path;
+			_title = (def.ContainsKey("title") ? def["title"] as string : String.Empty);
+			_author = (def.ContainsKey("author") ? def["author"] as string : String.Empty);
+			_version = (def.ContainsKey("version") ? def["version"] as string : String.Empty);
 
 			if (def.ContainsKey("web site"))
@@ -92,5 +62,5 @@
 				try 
 				{
-					faceDef.WebSite = new Uri(def["web site"] as string);
+					_webSite = new Uri(def["web site"] as string);
 				} 
 				catch (UriFormatException) {}
@@ -103,5 +73,4 @@
 			{
 				// throw new IOException();
-				return null;
 			}
 
@@ -112,19 +81,65 @@
 				int x = (int)partDef["pos x"];
 				int y = (int)partDef["pos y"];
-				faceDef.Parts.Add(new Part(System.IO.Path.Combine(path, filename), x, y));
+				_parts.Add(new Part(System.IO.Path.Combine(path, filename), x, y));
 			}
 
-			// TODO: pattern ðÇÝÞB
-			faceDef._patterns = new FacePattern(faceDef.Parts, def["pattern"] as ArrayList);
-
-			return faceDef;
-		}
-	}
-
-	public enum MarkerBitMask
-	{
-		None    = 0x0000,
-		PageIn  = 0x0001,
-		PageOut = 0x0002
+			_patternSuites = new PartList[PatternCols][];
+			ArrayList patternDefSuites = def["pattern"] as ArrayList;
+			for (int i = 0; i < PatternRows; i++) 
+			{
+				PartList[] suite = new PartList[PatternCols];
+				ArrayList patternDefList = patternDefSuites[i] as ArrayList;
+				for (int j = 0; j < PatternCols; j++) 
+				{
+					PartList pattern = new PartList();
+					foreach (int partNo in (ArrayList)patternDefList[j]) 
+					{
+						pattern.Add(_parts[partNo]);
+					}
+					suite[j] = pattern;
+				}
+				_patternSuites[i] = suite;
+			}
+		}
+
+		public PartList Markers
+		{
+			get { return _makers; }
+		}
+
+		public PartList Parts
+		{
+			get { return _parts; }
+		}
+
+		public Uri WebSite
+		{
+			get { return _webSite; }
+		}
+
+		public string /*Version*/ Version
+		{
+			get { return _version; }
+		}
+
+		public string Author
+		{
+			get { return _author; }
+		}
+
+		public string Title
+		{
+			get { return _title; }
+		}
+
+		public string Path
+		{
+			get { return _path; }
+		}
+
+		public PartList Pattern(PatternSuite suite, int no)
+		{
+			return _patternSuites[(int)suite][no];
+		}
 	}
 
Index: unk/MacFaceLibrary/FacePattern.cs
===================================================================
--- /trunk/MacFaceLibrary/FacePattern.cs	(revision 15)
+++ 	(revision )
@@ -1,72 +1,0 @@
-/*
- * FacePattern.cs
- * $Id$
- * 
- */
-
-using System;
-using System.Collections;
-
-namespace MacFace
-{
-	public enum PageOutFlag
-	{
-		Normal,
-		PageOut,
-		PageOutLarge
-	}
-
-	/// <summary>
-	/// FacePattern ÌTvÌà¾Å·B
-	/// </summary>
-	public class FacePattern
-	{
-		private PartList[] _partsMemNormal   = new PartList[11];
-		private PartList[] _partsMemPageOut  = new PartList[11];
-		private PartList[] _partsMemPageOutL = new PartList[11];
-
-		protected PartList[] MemoryNormal { get { return _partsMemNormal; } }
-		protected PartList[] MemoryPageOut { get { return _partsMemPageOut; } }
-		protected PartList[] MemoryPageOutLarge { get { return _partsMemPageOutL; } }
-
-		public PartList GetPartList(int cpuUsagePct, PageOutFlag pageOut)
-		{
-			PartList[] partlist = null;
-			switch (pageOut) 
-			{
-				case PageOutFlag.Normal: partlist = _partsMemNormal; break;
-				case PageOutFlag.PageOut: partlist = _partsMemPageOut; break;
-				case PageOutFlag.PageOutLarge: partlist = _partsMemPageOutL; break;
-			}
-			return partlist[cpuUsagePct/10];
-		}
-
-		public FacePattern(PartList faceParts, ArrayList patterns)
-		{
-			// Ì3p^[
-			for (int i = 0; i < 3; i++) 
-			{
-				PartList[] partlist = null;
-				switch (i) 
-				{
-					case 0: partlist = _partsMemNormal; break;
-					case 1: partlist = _partsMemPageOut; break;
-					case 2: partlist = _partsMemPageOutL; break;
-					default: break;
-				}
-
-				ArrayList patternByMem = patterns[i] as ArrayList;
-				// CPU Ì11p^[B
-				for (int j = 0; j < 11; j++) 
-				{
-					partlist[j] = new PartList();
-					ArrayList facePattern = patternByMem[j] as ArrayList;
-					foreach (int patNo in facePattern) 
-					{
-						partlist[j].Add(faceParts[patNo]);
-					}
-				}
-			}
-		}
-	}
-}
Index: /trunk/MacFaceLibrary/MacFaceLibrary.csproj
===================================================================
--- /trunk/MacFaceLibrary/MacFaceLibrary.csproj	(revision 15)
+++ /trunk/MacFaceLibrary/MacFaceLibrary.csproj	(revision 16)
@@ -105,9 +105,4 @@
                 />
                 <File
-                    RelPath = "FacePattern.cs"
-                    SubType = "Code"
-                    BuildAction = "Compile"
-                />
-                <File
                     RelPath = "HostStatistics.cs"
                     SubType = "Code"
