Class NamingUtils
java.lang.Object
com.sun.corba.ee.impl.naming.cosnaming.NamingUtils
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic boolean
Debug flag which must be true for debug streams to be created and dprint output to be generated.static PrintStream
The debug printstream.static PrintStream
The error printstream. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic void
Prints the message to the debug stream if debugging is enabled.static void
Prints the message to the error stream (System.err is default).(package private) static String
A utility method that takes Array of NameComponent and converts into a directory structured name in the format of /id1.kind1/id2.kind2..static void
makeDebugStream
(File logFile) Create a debug print stream to the supplied log file.static void
makeErrStream
(File errFile) Create a error print stream to the supplied file.static void
Prints the stacktrace of the supplied exception to the error stream.
-
Field Details
-
debug
public static boolean debugDebug flag which must be true for debug streams to be created and dprint output to be generated. -
debugStream
The debug printstream. -
errStream
The error printstream.
-
-
Constructor Details
-
NamingUtils
private NamingUtils()
-
-
Method Details
-
dprint
Prints the message to the debug stream if debugging is enabled.- Parameters:
msg
- the debug message to print.
-
errprint
Prints the message to the error stream (System.err is default).- Parameters:
msg
- the error message to print.
-
printException
Prints the stacktrace of the supplied exception to the error stream.- Parameters:
e
- any Java exception.
-
makeDebugStream
Create a debug print stream to the supplied log file.- Parameters:
logFile
- the file to which debug output will go.- Throws:
IOException
- thrown if the file cannot be opened for output.
-
makeErrStream
Create a error print stream to the supplied file.- Parameters:
errFile
- the file to which error messages will go.- Throws:
IOException
- thrown if the file cannot be opened for output.
-
getDirectoryStructuredName
A utility method that takes Array of NameComponent and converts into a directory structured name in the format of /id1.kind1/id2.kind2.. This is used mainly for Logging.
-