Codota Logo
CmsRelationType.getLocalizedName
Code IndexAdd Codota to your IDE (free)

How to use
getLocalizedName
method
in
org.opencms.relations.CmsRelationType

Best Java code snippets using org.opencms.relations.CmsRelationType.getLocalizedName (Showing top 12 results out of 315)

  • Add the Codota plugin to your IDE and get smart completions
private void myMethod () {
StringBuilder s =
  • Codota Iconnew StringBuilder()
  • Codota Iconnew StringBuilder(32)
  • Codota IconString str;new StringBuilder(str)
  • Smart code suggestions by Codota
}
origin: org.opencms/opencms-core

/**
 * Returns a localized name for the given relation type.<p>
 *
 * @param locale the locale
 *
 * @return a localized name
 */
public String getLocalizedName(Locale locale) {
  return getLocalizedName(Messages.get().getBundle(locale));
}
origin: org.opencms/opencms-solr

/**
 * Returns a localized name for the given relation type.<p>
 * 
 * @param locale the locale
 * 
 * @return a localized name
 */
public String getLocalizedName(Locale locale) {
  return getLocalizedName(Messages.get().getBundle(locale));
}
origin: org.opencms/opencms-solr

/**
 * @see org.opencms.workplace.list.A_CmsListExplorerDialog#getListItems()
 */
@Override
protected List getListItems() throws CmsException {
  List newItems = new ArrayList();
  List items = super.getListItems();
  Iterator itItems = items.iterator();
  while (itItems.hasNext()) {
    CmsListItem item = (CmsListItem)itItems.next();
    CmsResource resource = getResourceUtil(item).getResource();
    CmsRelationType relationType = (CmsRelationType)((List)getRelationTypes().get(resource)).remove(0);
    String localizedRelationType = relationType.getLocalizedName(getMessages());
    Map itemValues = item.getValues();
    CmsListItem newItem = getList().newItem(localizedRelationType + "_" + resource.getStructureId().toString());
    Iterator itItemValuesKeys = itemValues.entrySet().iterator();
    while (itItemValuesKeys.hasNext()) {
      Map.Entry e = (Map.Entry)itItemValuesKeys.next();
      String currentKey = (String)e.getKey();
      newItem.set(currentKey, e.getValue());
    }
    newItem.set(LIST_COLUMN_RELATION_TYPE, localizedRelationType);
    newItems.add(newItem);
  }
  return newItems;
}
origin: org.opencms/org.opencms.workplace

/**
 * @see org.opencms.workplace.list.A_CmsListExplorerDialog#getListItems()
 */
@Override
protected List<CmsListItem> getListItems() throws CmsException {
  List<CmsListItem> newItems = new ArrayList<CmsListItem>();
  List<CmsListItem> items = super.getListItems();
  Iterator<CmsListItem> itItems = items.iterator();
  while (itItems.hasNext()) {
    CmsListItem item = itItems.next();
    CmsResource resource = getResourceUtil(item).getResource();
    CmsRelationType relationType = getRelationTypes().get(resource).remove(0);
    String localizedRelationType = relationType.getLocalizedName(getMessages());
    Map<String, Object> itemValues = item.getValues();
    CmsListItem newItem = getList().newItem(localizedRelationType + "_" + resource.getStructureId().toString());
    Iterator<Entry<String, Object>> itItemValuesKeys = itemValues.entrySet().iterator();
    while (itItemValuesKeys.hasNext()) {
      Entry<String, Object> e = itItemValuesKeys.next();
      String currentKey = e.getKey();
      newItem.set(currentKey, e.getValue());
    }
    newItem.set(LIST_COLUMN_RELATION_TYPE, localizedRelationType);
    newItems.add(newItem);
  }
  return newItems;
}
origin: org.opencms/org.opencms.workplace

html.append(relation.getType().getLocalizedName(getMessages()));
html.append(")</span>");
if (itRelations.hasNext()) {
origin: org.opencms/opencms-solr

html.append(relation.getType().getLocalizedName(getMessages()));
html.append(")</span>");
if (itRelations.hasNext()) {
origin: org.opencms/org.opencms.workplace

html.append(relation.getType().getLocalizedName(getMessages()));
html.append(")</span>");
if (itRelations.hasNext()) {
origin: org.opencms/opencms-solr

html.append(relation.getType().getLocalizedName(getMessages()));
html.append(")</span>");
if (itRelations.hasNext()) {
origin: org.opencms/opencms-solr

  0);
if (!brokenLinks.contains(resource)) {
  brokenLinks.add(relation.getType().getLocalizedName(
    getWp().getJsp().getRequestContext().getLocale())
    + "_"
origin: org.opencms/org.opencms.workplace

if (!brokenLinks.contains(resource)) {
  brokenLinks.add(
    relation.getType().getLocalizedName(getWp().getJsp().getRequestContext().getLocale())
      + "_"
      + resource.getStructureId());
origin: org.opencms/opencms-solr

/**
 * Adds a new relation to the given resource.<p>
 * 
 * @param dbc the database context
 * @param resource the resource to add the relation to
 * @param target the target of the relation
 * @param type the type of the relation
 * @param importCase if importing relations
 * 
 * @throws CmsException if something goes wrong
 */
public void addRelationToResource(
  CmsDbContext dbc,
  CmsResource resource,
  CmsResource target,
  CmsRelationType type,
  boolean importCase) throws CmsException {
  if (type.isDefinedInContent()) {
    throw new CmsIllegalArgumentException(Messages.get().container(
      Messages.ERR_ADD_RELATION_IN_CONTENT_3,
      dbc.removeSiteRoot(resource.getRootPath()),
      dbc.removeSiteRoot(target.getRootPath()),
      type.getLocalizedName(dbc.getRequestContext().getLocale())));
  }
  CmsRelation relation = new CmsRelation(resource, target, type);
  m_vfsDriver.createRelation(dbc, dbc.currentProject().getUuid(), relation);
  if (!importCase) {
    setDateLastModified(dbc, resource, System.currentTimeMillis());
  }
}
origin: org.opencms/opencms-core

dbc.removeSiteRoot(resource.getRootPath()),
dbc.removeSiteRoot(target.getRootPath()),
type.getLocalizedName(dbc.getRequestContext().getLocale())));
org.opencms.relationsCmsRelationTypegetLocalizedName

Javadoc

Returns a localized name for the given relation type.

Popular methods of CmsRelationType

  • <init>
    Private constructor for system relation types.
  • filterDefinedInContent
    Returns all relation types in the given list that define relations in the content.
  • filterInternal
    Returns all internal defined relation types in the given list.
  • filterNotDefinedInContent
    Returns all relation types in the given list that are not defined in the content.
  • filterStrong
    Returns all strong relation types in the given list.
  • filterUserDefined
    Returns all user defined relation types in the given list.
  • filterWeak
    Returns all weak relation types in the given list.
  • getAll
    Returns all relation types.
  • getAllDefinedInContent
    Returns all relation types for relations defined in the content.
  • getAllInternal
    Returns all internally defined relation types.
  • getAllNotDefinedInContent
    Returns all relation types for relations that are not defined in the content.
  • getAllStrong
    Returns all strong relation types.
  • getAllNotDefinedInContent,
  • getAllStrong,
  • getAllUserDefined,
  • getAllWeak,
  • getId,
  • getName,
  • getNameForXml,
  • getType,
  • hashCode

Popular in Java

  • Reactive rest calls using spring rest template
  • runOnUiThread (Activity)
  • findViewById (Activity)
  • compareTo (BigDecimal)
    Compares this BigDecimal with the specified BigDecimal. Two BigDecimal objects that are equal in val
  • InputStreamReader (java.io)
    An InputStreamReader is a bridge from byte streams to character streams: It reads bytes and decodes
  • System (java.lang)
    Provides access to system-related information and resources including standard input and output. Ena
  • MessageFormat (java.text)
    MessageFormat provides a means to produce concatenated messages in language-neutral way. Use this to
  • Collections (java.util)
    This class consists exclusively of static methods that operate on or return collections. It contains
  • Iterator (java.util)
    An iterator over a collection. Iterator takes the place of Enumeration in the Java Collections Frame
  • Options (org.apache.commons.cli)
    Main entry-point into the library. Options represents a collection of Option objects, which describ
Codota Logo
  • Products

    Search for Java codeSearch for JavaScript codeEnterprise
  • IDE Plugins

    IntelliJ IDEAWebStormAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogCodota Academy Plugin user guide Terms of usePrivacy policyJava Code IndexJavascript Code Index
Get Codota for your IDE now