//
// Caitlin Howell
// CS577, Homework 4
// LCS Dynamic Programming Algorithm Implemenation
// Due December 9, 1997
//
// File LCSCell.java
//
// Class LCSCell makes up each individual cell in the LCS tabel
// Each cell stores a directional arrow and the total length of the longest
// common string.
			
public class LCSCell
{

	// total stores the total length of the longest common string
	// that the cell describes
	private int total;

	// Because Java contains no enumerated types, and it seems like a 
	// waste to declare a whole new class to represent a 2-bit value,
	// char is used to represent the directional value.
	// '\' ('\\' in Java) is diagonal
	// '^' is up
	// '<' is left
	// '+' is undefined
	private char arrow;
	
	public LCSCell(int T, char a)
	{
		total = T;
		arrow = a;
	}

	public void changeTotal(int tot)
	{ 
		total = tot;
	}

	public void changeArrow(char arr)
	{
		arrow = arr;
	}
	
	public int total()
	{
		return total;
	}

	public char arrow()
	{
		return arrow;
	}
}

