Klasse Camelbacker

java.lang.Object
org.apache.torque.generator.processor.string.Camelbacker
Alle implementierten Schnittstellen:
StringProcessor

public class Camelbacker extends Object implements StringProcessor
Creates a String in CaMelBaCk case from a String with special characters
  • Konstruktorübersicht

    Konstruktoren
    Konstruktor
    Beschreibung
     
  • Methodenübersicht

    Modifizierer und Typ
    Methode
    Beschreibung
    Returns the separation chars which define the tail to be removed.
    Returns the separation characters which defile the prefix to be removed.
    Returns which characters are removed from the processed String.
    Returns the characters which are removed from the processed String and cause the following character to be converted to upper case.
    boolean
    Returns whether all characters in the processed String should be made lower Case by default (i.e if none of the camelback rules is applicable).
    boolean
    Returns whether the first character is always converted to upper case.
    process(String toProcess)
    Does the camelback processing according to the settings.
    void
    setDefaultLowerCase(boolean defaultLowerCase)
    Sets whether all characters in the processed String should be made lower Case by default (i.e if none of the camelback rules is applicable).
    void
    setFirstCharUppercase(boolean firstCharUppercase)
    Sets whether the first character should always be upper case.
    void
    setIgnorePartAfter(String ignorePartAfter)
    Sets the separation chars which define the suffix to be removed.
    void
    setIgnorePartBefore(String ignorePartBefore)
    Sets the separation characters which define the prefix to be removed.
    void
    setRemoveWithoutUppercase(String removeWithoutUppercase)
    Sets which characters are removed from the processed String.
    void
    setRemoveWithUppercase(String removeWithUppercase)
    Sets the characters which are removed from the processed String and cause the following character to be converted to upper case.

    Von Klasse geerbte Methoden java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Konstruktordetails

    • Camelbacker

      public Camelbacker()
  • Methodendetails

    • process

      public String process(String toProcess)
      Does the camelback processing according to the settings.
      Angegeben von:
      process in Schnittstelle StringProcessor
      Parameter:
      toProcess - the String to process.
      Gibt zurück:
      the processed String.
    • isFirstCharUppercase

      public boolean isFirstCharUppercase()
      Returns whether the first character is always converted to upper case.
      Gibt zurück:
      true if the first character is always converted to upper case, false if not.
    • setFirstCharUppercase

      public void setFirstCharUppercase(boolean firstCharUppercase)
      Sets whether the first character should always be upper case. Default is true.
      Parameter:
      firstCharUppercase - true if the first character should always be converted to upper case, false if not.
    • getIgnorePartAfter

      public String getIgnorePartAfter()
      Returns the separation chars which define the tail to be removed. If one of the characters in this String is encountered in the processed String, the part of the processed String after it are ignored. The character itself is retained, unless it is removed by another rule.
      Gibt zurück:
      the separation chars for removing the tail.
    • setIgnorePartAfter

      public void setIgnorePartAfter(String ignorePartAfter)
      Sets the separation chars which define the suffix to be removed. If one of the characters in this String is encountered in the processed String, the part of the processed String after it are ignored. The character itself is retained, unless it is removed by another rule.
      Parameter:
      ignorePartAfter - the separation chars for removing the tail.
    • getIgnorePartBefore

      public String getIgnorePartBefore()
      Returns the separation characters which defile the prefix to be removed. If one of the characters in this String is encountered in the processed String, the part of the processed String before it are ignored. The character itself is retained, unless it is removed by another rule.
      Gibt zurück:
      the separation chars which define the suffix to be removed.
    • setIgnorePartBefore

      public void setIgnorePartBefore(String ignorePartBefore)
      Sets the separation characters which define the prefix to be removed. If one of the characters in this String is encountered in the processed String, the part of the processed String before it are ignored. The character itself is retained, unless it is removed by another rule.
      Parameter:
      ignorePartBefore - the separation chars which define the suffix to be removed.
    • getRemoveWithoutUppercase

      public String getRemoveWithoutUppercase()
      Returns which characters are removed from the processed String.
      Gibt zurück:
      a String containing all characters which are simply removed from the input String.
    • setRemoveWithoutUppercase

      public void setRemoveWithoutUppercase(String removeWithoutUppercase)
      Sets which characters are removed from the processed String. Default is "."
      Parameter:
      removeWithoutUppercase - a String containing all characters which are simply removed from the input String.
    • getRemoveWithUppercase

      public String getRemoveWithUppercase()
      Returns the characters which are removed from the processed String and cause the following character to be converted to upper case.
      Gibt zurück:
      a String containing all characters which are removed from the input String and which cause the following character to be converted to upper case.
    • setRemoveWithUppercase

      public void setRemoveWithUppercase(String removeWithUppercase)
      Sets the characters which are removed from the processed String and cause the following character to be converted to upper case. Default is "_-"
      Parameter:
      removeWithUppercase - a String containing all characters which are removed from the input String and which cause the following character to be converted to upper case.
    • isDefaultLowerCase

      public boolean isDefaultLowerCase()
      Returns whether all characters in the processed String should be made lower Case by default (i.e if none of the camelback rules is applicable).
      Gibt zurück:
      true if all characters are converted to lower case by default, false if not.
    • setDefaultLowerCase

      public void setDefaultLowerCase(boolean defaultLowerCase)
      Sets whether all characters in the processed String should be made lower Case by default (i.e if none of the camelback rules is applicable). Default is true.
      Parameter:
      defaultLowerCase - true if all characters are converted to lower case by default, false if not.