Follow Techotopia on Twitter

On-line Guides
All Guides
eBook Store
iOS / Android
Linux for Beginners
Office Productivity
Linux Installation
Linux Security
Linux Utilities
Linux Virtualization
Linux Kernel
System/Network Admin
Programming
Scripting Languages
Development Tools
Web Development
GUI Toolkits/Desktop
Databases
Mail Systems
openSolaris
Eclipse Documentation
Techotopia.com
Virtuatopia.com
Answertopia.com

How To Guides
Virtualization
General System Admin
Linux Security
Linux Filesystems
Web Servers
Graphics & Desktop
PC Hardware
Windows
Problem Solutions
Privacy Policy

  




 

 

RSE
Release 3.0

org.eclipse.rse.ui
Class MassagerFoldCase


java.lang.Object
  extended by 
org.eclipse.rse.ui.MassagerFoldCase
All Implemented Interfaces:
ISystemMassager
Direct Known Subclasses:
MassagerFoldCaseOutsideQuotes, MassagerFoldCaseUnlessQuoted

public class MassagerFoldCase
extends Object
implements ISystemMassager

This massager folds the input text into either uppercase or lowercase, depending on the value pass to the constructor or setter.

Note by default this also trims the


Constructor Summary
MassagerFoldCase ()
          Constructor using uppercase as the case direction
MassagerFoldCase (boolean foldToUpperCase)
          Constructor using given case direction
 
Method Summary
 boolean getFoldToUpperCase ()
          Return property about whether to fold to uppercase or lowercase
 boolean getTrimBlanks ()
          Return property about whether to trim blanks for not
  String massage ( String text)
          Given the user-entered input, return the massaged version of it.
 void setFoldToUpperCase (boolean foldToUpperCase)
          Toggle whether to fold to uppercase or lowercase
 void setTrimBlanks (boolean trimBlanks)
          Toggle whether to trim blanks for not
protected   String toLowerCase ( String input)
          Overrridable method that actually does the lowercasing
protected   String toUpperCase ( String input)
          Overrridable method that actually does the uppercasing
 
Methods inherited from class java.lang. Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MassagerFoldCase

public MassagerFoldCase()
Constructor using uppercase as the case direction


MassagerFoldCase

public MassagerFoldCase(boolean foldToUpperCase)
Constructor using given case direction

Parameters:
foldToUpperCase - - whether to fold to uppercase (true) or lowercase (false).
Method Detail

setFoldToUpperCase

public void setFoldToUpperCase(boolean foldToUpperCase)
Toggle whether to fold to uppercase or lowercase

Parameters:
foldToUpperCase - - whether to fold to uppercase (true) or lowercase (false).

setTrimBlanks

public void setTrimBlanks(boolean trimBlanks)
Toggle whether to trim blanks for not

Parameters:
trimBlanks - - whether to trim blanks (true) or leave them (false).

getFoldToUpperCase

public boolean getFoldToUpperCase()
Return property about whether to fold to uppercase or lowercase

Returns:
true if folder to uppercase, false if folded to lowercaese

getTrimBlanks

public boolean getTrimBlanks()
Return property about whether to trim blanks for not

Returns:
true if blanks are trimmed

massage

public 
String massage(
String text)
Description copied from interface: ISystemMassager
Given the user-entered input, return the massaged version of it. If no massaging required, return the input as is.

Specified by:
massage in interface ISystemMassager
See Also:
ISystemMassager.massage(String)

toUpperCase

protected 
String toUpperCase(
String input)
Overrridable method that actually does the uppercasing


toLowerCase

protected 
String toLowerCase(
String input)
Overrridable method that actually does the lowercasing


RSE
Release 3.0

Copyright (c) IBM Corporation and others 2000, 2008. All Rights Reserved.

 
 
  Published under the terms of the Eclipse Public License Version 1.0 ("EPL") Design by Interspire