|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectfedora.client.demo.DemoObjectConverter
public class DemoObjectConverter
Title: DemoObjectConverter.java
Description: Goes through the Fedora demo objects directory and changes all occurrences of strings for protocol, hostname and port number to values supplied by the user in the calling arguments. This utility is used to convert the original Fedora demo objects so that they will function correctly when the Fedora server is configured to run on a protocol, host, or port other than the defaults.
| Constructor Summary | |
|---|---|
DemoObjectConverter(java.lang.String fromProtocol,
java.lang.String fromHostName,
java.lang.String fromPortNum,
java.lang.String toProtocol,
java.lang.String toHostName,
java.lang.String toPortNum,
java.lang.String fedoraHome)
Constructor for DemoObjectConverter. |
|
| Method Summary | |
|---|---|
static void |
convert(java.lang.String fedoraHome)
Converts all Fedora demo objects by substituting hostname and port numer supplied in calling arguments. |
static void |
getFiles(java.io.File dir)
Recursively traverse the specified directory and process each file.<.p> |
static void |
main(java.lang.String[] args)
|
static void |
showUsage(java.lang.String errMessage)
Shows argument list for application. |
static void |
substitute(java.io.File demoObject)
Substitute the protocol, hostname and port number supplied in calling arguments with those found in Fedora demo objects. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public DemoObjectConverter(java.lang.String fromProtocol,
java.lang.String fromHostName,
java.lang.String fromPortNum,
java.lang.String toProtocol,
java.lang.String toHostName,
java.lang.String toPortNum,
java.lang.String fedoraHome)
Constructor for DemoObjectConverter. Initializes class variables for hostname, port number and fedoraHome.
fromProtocol - The protocol for the URL to be changed from.fromHostName - The host name to be changed from.fromPortNum - The port number to be changed from.toProtocol - The protocol for the URL to be changed to.toHostName - The host name to be changed to.toPortNum - The port number ot be changed to.fedoraHome - The installation directory for Fedora.| Method Detail |
|---|
public static void convert(java.lang.String fedoraHome)
Converts all Fedora demo objects by substituting hostname and port numer supplied in calling arguments.
fedoraHome - The location Fedora is installed.public static void getFiles(java.io.File dir)
Recursively traverse the specified directory and process each file.<.p>
dir - The directory to be traversed.public static void substitute(java.io.File demoObject)
Substitute the protocol, hostname and port number supplied in calling arguments with those found in Fedora demo objects. Replaces the original file with the edited version.
demoObject - The Fedora demo object file to be edited.public static void showUsage(java.lang.String errMessage)
Shows argument list for application.
errMessage - The message to be included with usage information.public static void main(java.lang.String[] args)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||