01: /*******************************************************************************
02: * Copyright (c) 2004, 2006 IBM Corporation and others.
03: * All rights reserved. This program and the accompanying materials
04: * are made available under the terms of the Eclipse Public License v1.0
05: * which accompanies this distribution, and is available at
06: * http://www.eclipse.org/legal/epl-v10.html
07: *
08: * Contributors:
09: * IBM Corporation - initial API and implementation
10: *******************************************************************************/package org.eclipse.ui.internal.intro.impl.model;
11:
12: import org.eclipse.core.runtime.IConfigurationElement;
13:
14: /**
15: * An intro standby content part registration. This model class does not appear
16: * as a child under any of the other model classes. It is returned by the
17: * ExtensionPointManager when asked for registration parts.
18: */
19: public class IntroStandbyContentPart extends AbstractIntroIdElement {
20:
21: public static final String TAG_STANDBY_CONTENT_PART = "standbyContentPart"; //$NON-NLS-1$
22:
23: private static final String ATT_PLUGIN_ID = "pluginId"; //$NON-NLS-1$
24: private static final String ATT_CLASS = "class"; //$NON-NLS-1$
25:
26: private String pluginId;
27: private String className;
28:
29: /**
30: * Note: model class with public constructor because it is not instantiated
31: * by the model root.
32: *
33: * @param element
34: */
35: public IntroStandbyContentPart(IConfigurationElement element) {
36: super (element);
37: pluginId = element.getAttribute(ATT_PLUGIN_ID);
38: className = element.getAttribute(ATT_CLASS);
39: }
40:
41: /**
42: * @return Returns the className.
43: */
44: public String getClassName() {
45: return className;
46: }
47:
48: /**
49: * @return Returns the pluginId.
50: */
51: public String getPluginId() {
52: return pluginId;
53: }
54:
55: /*
56: * (non-Javadoc)
57: *
58: * @see org.eclipse.ui.internal.intro.impl.model.IntroElement#getType()
59: */
60: public int getType() {
61: // this model class does not need a type so far.
62: return 0;
63: }
64: }
|