How to Use the Obix Framework

1) Create the sample.config file:

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE configuration SYSTEM "">
  <entry entryKey="message">
    <value>Hello World!</value>

2) Create the file:

import static java.lang.System.out;

import org.obix.configuration.Configuration;
import org.obix.configuration.ConfigurationAdapter;
import org.obix.configuration.ConfigurationAdapterFactory;

public final class ObixSample {

  public static void main(final String[] args) {
    final ConfigurationAdapterFactory factory = ConfigurationAdapterFactory.newAdapterFactory();

    final Configuration config = Configuration.getConfiguration();

    final ConfigurationAdapter adapter = factory.create(null);

    adapter.adaptConfiguration(config, "sample.config");



3) Compile the file.

4) Launch the ObixSample class.


Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.