Main.java Source code

Java tutorial

Introduction

Here is the source code for Main.java

Source

//package com.java2s;
/******************************************************************************
 * Copyright (c) 2006, 2010 VMware Inc.
 * All rights reserved. This program and the accompanying materials
 * are made available under the terms of the Eclipse Public License v1.0
 * and Apache License v2.0 which accompanies this distribution. 
 * The Eclipse Public License is available at 
 * http://www.eclipse.org/legal/epl-v10.html and the Apache License v2.0
 * is available at http://www.opensource.org/licenses/apache2.0.php.
 * You may elect to redistribute this code under either of these licenses. 
 * 
 * Contributors:
 *   VMware Inc.
 *****************************************************************************/

import java.util.Dictionary;

public class Main {
    /** Manifest entry name for configuring Blueprint modules */
    public static final String BLUEPRINT_HEADER = "Bundle-Blueprint";

    /**
     * Returns the {@value #BLUEPRINT_HEADER} if present from the given dictionary.
     * 
     * @param headers
     * @return
     */
    public static String getBlueprintHeader(Dictionary headers) {
        Object header = null;
        if (headers != null)
            header = headers.get(BLUEPRINT_HEADER);
        return (header != null ? header.toString().trim() : null);
    }
}