001/*
002 * Copyright (c) 2006-2011 Nuxeo SA (http://nuxeo.com/) and others.
003 *
004 * All rights reserved. This program and the accompanying materials
005 * are made available under the terms of the Eclipse Public License v1.0
006 * which accompanies this distribution, and is available at
007 * http://www.eclipse.org/legal/epl-v10.html
008 *
009 * Contributors:
010 *     bstefanescu
011 */
012package org.nuxeo.runtime.model.persistence;
013
014import java.io.InputStream;
015
016import org.nuxeo.runtime.model.StreamRef;
017
018/**
019 * @author <a href="mailto:bs@nuxeo.com">Bogdan Stefanescu</a>
020 */
021public interface Contribution extends StreamRef {
022
023    /**
024     * Gets the contribution name.
025     */
026    String getName();
027
028    /**
029     * Gets the contribution description.
030     */
031    String getDescription();
032
033    /**
034     * Sets the contribution description.
035     */
036    void setDescription(String description);
037
038    /**
039     * Whether this contribution should be automatically installed at startup.
040     */
041    boolean isDisabled();
042
043    /**
044     * Sets the auto install flag for this contribution.
045     */
046    void setDisabled(boolean isAutoStart);
047
048    /**
049     * Gets the contribution XML content. The content should be in Nuxeo XML component format.
050     */
051    @Override
052    InputStream getStream();
053
054    /**
055     * Gets the contribution XML content. The content should be in Nuxeo XML component format.
056     */
057    String getContent();
058
059}