Welcome To Snipplr


Everyone's Recent Java Snippets Tagged class



« Prev 1 Next »
  1. FAV

    Helper method to print to the console

    Ever got tired of writing System.out.print(); all the time when testing, well, to avoid this, just create a helper method that will narrow it down to print();
    Java 4 views posted 9 years ago by visudex
  2. FAV

    Read User Input Java with Scanner Class

    This snippet will allow you to read user's input when they write in the console. This method uses the Scanner class, which is my favorite way of doing instead of using the Buffered Reader, with the Scanner, you can also read from a file.
    Java 4 views posted 9 years ago by visudex
  3. FAV

    Test Class for Lead Reassignment

    This is the test class for the LeadReassignment class.
    Java 1 views posted 9 years ago by leeclint
  4. FAV

    cisp401 MyString.java

    Great for formatting.
    Java saved by 1 person 2 views posted 9 years ago by trusktr
  5. FAV

    Changing Header Class (CSS) in JSF Datatables - Codedropâ„¢ Weblog

    Something I have always found annoying about JSF datatables is the limitation to only apply one header class style to the entire table. This is un-functional for datatables that would display monetary amount or other data that is typically right alig...
    Java 5 views posted 9 years ago by adriamooney
  6. FAV

    Finding classes

    Using http://www.clapper.org/software/java/util/javadocs/util/api/org/clapper/util/classutil/ClassFinder.html in order to find a class in class path.
    Java 2 views posted 9 years ago by narkisr
  7. FAV

    Simple Times Table Generator

    Adapted the simple code the lecturer was using to generate a times table, just to see if I "got" the concept properly.
    Java 3 views posted 10 years ago by joshnunn
  8. FAV

    RectangleTest.java

    This is a test driver class. It instantiates a few rectangles with varying lengths and widths and then prints their areas and perimeters. What is odd is the output I get from NetBeans for the "stupid" rectangle. The program prints its value as "12...
    Java 3 views posted 10 years ago by joshnunn
  9. FAV

    Luhn Formula (Algorithm)

    Test harness for an implementation of the Luhn algorithm that checks the validity of a credit card number.
    Java 6 views posted 11 years ago by Uzbekjon
« Prev 1 Next »