All Examples

package examples.io

Class Index

about this package

The standalone examples in this directory illustrate the WebLogic File API.

how to use this package

  1. Set up your development environment as described in Setting your development environment.

  2. In your development shell, compile the files in this directory to your CLIENT_CLASSES directory, with a command like this one for Windows NT:
      $ javac -d %CLIENT_CLASSES% *.java

  3. Set up a registered fileSystem in your weblogic.properties file by adding the weblogic.io.fileSystem property. You register a virtual name that the WebLogic Server maps to a real path that is valid on the server host. For example, to map the virtual name "mySys" to "c:\temp", you would add this property:
      weblogic.io.fileSystem.mySys=c:/temp

    Note the use of the forward slash--the Java convention--instead of a backwards slash. For more info on this property, check the Administrators Guide, Setting WebLogic properties.

  4. Start your WebLogic Server in your server shell.

  5. From your development shell, execute each example individually. You can type "java" plus the full package name to see a usage message on the arguments that each example requires.

    For example, here's how you run the FileBrowser example from the command line of the same machine as your WebLogic Server, listening on port 7001, with a registered fileSystem called "mySys":

      $ java examples.io.FileBrowser t3://localhost:7001 mySys

    With the FileBrowser example, you get a prompt that matches the name of your registered file system. You can toggle back and forth between your local file system and the WebLogic Server registered file system with the FileBrowser command "cf #" and "cf [fileSystem]". Type a question mark (?) to see a list of commands available in the FileBrowser.

there's more . . .

Read the Developers Guide, Using WebLogic File Services, to get more detailed information for your application.