Java Properties Load loadProperties()

Here you can find the source of loadProperties()

Description

load Properties

License

Apache License

Declaration

private static Properties loadProperties() 

Method Source Code


//package com.java2s;
//License from project: Apache License 

import java.io.BufferedInputStream;
import java.io.FileInputStream;
import java.io.IOException;
import java.io.InputStream;
import java.util.Properties;

public class Main {
    private final static String configFile = "src/jbehave/resources/config.properties";

    private static Properties loadProperties() {
        InputStream in = null;//from  ww w.j a  v a2s .  c o m
        Properties properties = new Properties();
        try {
            in = new BufferedInputStream(new FileInputStream(configFile));
            properties.load(in);
        } catch (IOException e) {
            e.printStackTrace();
        }

        return properties;
    }
}

Related

  1. loadProperties()
  2. loadProperties()
  3. loadProperties()
  4. loadProperties()
  5. loadProperties()
  6. loadProperties()
  7. loadProperties()
  8. loadProperties(ByteSource is)
  9. loadProperties(Class clazz, String name)