CharClass - return ch; } Public char nextChar() { return...

Info iconThis preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
p Package jPfPatPd.ch07.PrimitiveTyPeClasses; P Public class CharClass { Private char ch; Public CharClass() { ch = ' '; } Public CharClass(char c) { ch = c; } Public void setChar(char c) { ch = c; } Public int getChar() {
Background image of page 1
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: return ch; } Public char nextChar() { return (char)((int)ch + 1); } Public char PrevChar() { return (char)((int)ch - 1); } Public String toString() { return (String.valueOf(ch)); } }...
View Full Document

Ask a homework question - tutors are online