The Mozilla
Organization
Our Mission
Who We Are
Getting Involved
Community
Editorials
What's New
Newsbot
Development
Roadmap
Module Owners
Blue Sky
Projects
Status
Tools
Products
Source Code
Binaries
Documentation
License Terms
Bug Reports
Quality
Search
Feedback
Class calypso.util.Abacus
All Packages  This Package  Class Hierarchy  Class Search  Index

Class calypso.util.Abacus

java.lang.Object
   |
   +----calypso.util.Abacus

A class for counting in a variety of bases.


public class  Abacus
     extends java.lang.Object
{
          // Fields 9
     public static final String[] bases;
     protected static final String gAlphaChars;
     protected static final String gBinaryChars;
     protected static final String gHexChars;
     protected static final String gRomanCharsA;
     protected static final String gRomanCharsB;
     public static final String[] ones;
     public static final String[] teens;
     public static final String[] tens;

          // Constructors 1
     public Abacus();

          // Methods 9
     public static void PadPrint(int, int);
     public static void PadPrint(String, int);
     public static String getAlphaString(int);
     public static String getBinaryString(int);
     public static String getHexString(int);
     public static String getRomanString(int);
     public static String getSeriesString(int, String, int, int);
     public static String getSpokenString(int);
     public static void main(String[]);
}



Fields


ones

   public static final String[] ones

Formatting Strings


teens

   public static final String[] teens


tens

   public static final String[] tens


bases

   public static final String[] bases


gAlphaChars

   protected static final String gAlphaChars


gRomanCharsA

   protected static final String gRomanCharsA


gRomanCharsB

   protected static final String gRomanCharsB


gHexChars

   protected static final String gHexChars


gBinaryChars

   protected static final String gBinaryChars



Constructors


Abacus

   public Abacus() 

Default constructor




Methods


getAlphaString

   public static String getAlphaString(int aValue) 

Formats the value as an alpha string



getRomanString

   public static String getRomanString(int aValue) 

Convert the given integer value into a roman numeral string

Parameter Description
aValue - int to be converted to roman

Returns:
new string


getHexString

   public static String getHexString(int aValue) 

Convert the given integer value into a hexstring

Parameter Description
aValue - int to be converted to hex string

Returns:
new string


getBinaryString

   public static String getBinaryString(int aValue) 

Convert the given integer value into a string of binary digits

Parameter Description
aValue - int to be converted to binary string

Returns:
new string


getSpokenString

   public static String getSpokenString(int aValue) 

Convert the given integer value into spoken string (one, two, three...)

Parameter Description
aValue - int to be converted to hex string

Returns:
new stringbuffer


getSeriesString

   public static String getSeriesString(int aValue, 
                                        String aCharSet, 
                                        int anOffset, 
                                        int aBase) 

Convert the given integer value into a series string. These are any arbitrary but repeating pattern of characters.

Parameter Description
aValue - int to be converted to series string

Returns:
new string


PadPrint

   public static void PadPrint(int aValue, 
                               int width) 


PadPrint

   public static void PadPrint(String aString, 
                               int aWidth) 


main

   public static void main(String[] argv) 


All Packages  This Package  Class Hierarchy  Class Search  Index
Freshly brewed Java API Documentation automatically generated with polardoc Version 1.0.4

Copyright © 1998-1999 The Mozilla Organization.