BrightSide Workbench Full Report + Source Code
IContext.java
Go to the documentation of this file.
1 /*
2  * TurrĂ³ i Cutiller Foundation. License notice.
3  * Copyright (C) 2011 Lluis TurrĂ³ Cutiller <http://www.turro.org/>
4  *
5  * This program is free software: you can redistribute it and/or modify
6  * it under the terms of the GNU Affero General Public License as published by
7  * the Free Software Foundation, either version 3 of the License, or
8  * (at your option) any later version.
9  *
10  * This program is distributed in the hope that it will be useful,
11  * but WITHOUT ANY WARRANTY; without even the implied warranty of
12  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13  * GNU Affero General Public License for more details.
14  *
15  * You should have received a copy of the GNU Affero General Public License
16  * along with this program. If not, see <http://www.gnu.org/licenses/>.
17  */
18 package org.turro.elephant.context;
19 
20 import java.io.File;
21 import java.io.IOException;
22 import java.util.Set;
23 import javax.servlet.ServletException;
24 
32 public interface IContext {
37  public String getId();
43  public IContext getContext();
48  public String getType();
53  public String getTitle();
59  public String getName();
60  public String getExactName(String lang);
66  public String getName(String lang);
72  public void setName(String lang, String name);
77  public String getIcon();
82  public void setIcon(String icon);
88  public String getRedirection();
89  public String getTarget();
99  public IElement getDefaultElement(String type);
104  public Set<String> getDefaultLocales();
114  public String[] getLocaleSufixes(String preferredLocale);
121  public void setConstructor(IConstructor constructor, String path);
127  public String getFullPath();
132  public String getWebPath();
137  public String getPath();
142  public int getLevel();
147 // public String getVerbosePath();
148 // public String getVerbosePath(IContext root);
153  public File getFile();
158  public IContext getParent();
164  public IContext[] getAncestors();
169  public IContext[] getChildren();
174  public IContext[] getSiblings();
175 // /**
176 // * The element identifier must exists within this context.
177 // * @param idel Identifier of the element.
178 // * @return The IElement found or null.
179 // */
180 // public IElement getElementById(String idel);
188  public void startConstruction() throws ServletException, IOException;
201  public boolean inPath(IContext context);
202 }
IElement getDefaultElement(String type)
boolean inPath(IContext context)
String getExactName(String lang)
void setName(String lang, String name)
String[] getLocaleSufixes(String preferredLocale)
void setConstructor(IConstructor constructor, String path)