List of usage examples for java.util Collections unmodifiableMap
public static <K, V> Map<K, V> unmodifiableMap(Map<? extends K, ? extends V> m)
From source file:com.linkedin.restli.client.Request.java
@Deprecated public Request(URI uri, ResourceMethod method, RecordTemplate inputRecord, Map<String, String> headers, RestResponseDecoder<T> decoder, ResourceSpec resourceSpec, DataMap queryParams, List<String> resourcePath, String methodName) { _method = method;//from w w w. j av a 2s . c om _inputRecord = inputRecord; _headers = (headers == null) ? null : Collections.unmodifiableMap(headers); _decoder = decoder; _queryParams = (queryParams == null) ? null : Collections.unmodifiableMap(queryParams); _resourceSpec = resourceSpec; _methodName = methodName; _baseUriTemplate = null; _pathKeys = null; _uri = uri; _hasUri = true; _requestOptions = RestliRequestOptions.DEFAULT_OPTIONS; }
From source file:org.cloudfoundry.identity.uaa.provider.saml.idp.SamlServiceProviderConfigurator.java
public Map<String, SamlServiceProviderHolder> getSamlServiceProviderMapForZone(IdentityZone zone) { Map<String, SamlServiceProviderHolder> serviceProviders = getOrCreateSamlServiceProviderMapForZone(zone); return Collections.unmodifiableMap(serviceProviders); }
From source file:com.smartitengineering.cms.api.impl.type.ContentTypeImpl.java
@Override public Map<String, ContentStatus> getStatuses() { final Map<String, ContentStatus> statusMap = new LinkedHashMap<String, ContentStatus>(); if (contentStatus.isEmpty() && getParent() != null) { ContentType parentContentType = getParent().getContentType(); if (parentContentType != null) { return parentContentType.getStatuses(); } else {/*ww w . java2s. com*/ return Collections.emptyMap(); } } else if (!contentStatus.isEmpty()) { for (ContentStatus status : contentStatus) { statusMap.put(status.getName(), status); } return Collections.unmodifiableMap(statusMap); } else { final ContentStatus status = new ContentStatus() { public int getId() { return 1; } public ContentTypeId getContentType() { return getContentTypeID(); } public String getName() { return "default"; } }; statusMap.put(status.getName(), status); return Collections.unmodifiableMap(statusMap); } }
From source file:com.openshift.internal.restclient.ResourceFactory.java
public static Map<String, Class<? extends IResource>> getImplMap() { return Collections.unmodifiableMap(IMPL_MAP); }
From source file:com.ctriposs.rest4j.client.Request.java
@Deprecated public Request(URI uri, ResourceMethod method, RecordTemplate inputRecord, Map<String, String> headers, RestResponseDecoder<T> decoder, ResourceSpec resourceSpec, DataMap queryParams, List<String> resourcePath, String methodName) { _method = method;/*from w w w.j av a2s. c om*/ _inputRecord = inputRecord; _headers = (headers == null) ? null : Collections.unmodifiableMap(headers); _decoder = decoder; _queryParams = (queryParams == null) ? null : Collections.unmodifiableMap(queryParams); _resourceSpec = resourceSpec; _methodName = methodName; _baseUriTemplate = null; _pathKeys = null; _uri = uri; _hasUri = true; _requestOptions = Rest4JRequestOptions.DEFAULT_OPTIONS; }
From source file:de.eonas.opencms.parserimpl.RelativePortalURLImpl.java
public Map<String, WindowState> getWindowStates() { return Collections.unmodifiableMap(windowStates); }
From source file:org.wikidata.wdtk.datamodel.json.jackson.JacksonTermedStatementDocument.java
@Override public Map<String, List<MonolingualTextValue>> getAliases() { // because of the typing provided by the interface one has to // re-create the map anew, simple casting is not possible Map<String, List<MonolingualTextValue>> returnMap = new HashMap<>(); for (Entry<String, List<JacksonMonolingualTextValue>> entry : this.aliases.entrySet()) { returnMap.put(entry.getKey(), Collections.<MonolingualTextValue>unmodifiableList(entry.getValue())); }//from ww w .ja va2 s . co m return Collections.unmodifiableMap(returnMap); }
From source file:eu.spaziodati.datatxt.stanbol.enhancer.engines.DatatxtNexEngine.java
public Map<String, Object> getServiceProperties() { return Collections.unmodifiableMap( Collections.singletonMap(ServiceProperties.ENHANCEMENT_ENGINE_ORDERING, (Object) DEFAULT_ORDER)); }
From source file:com.ciphertool.sentencebuilder.dao.BasicWordMapDao.java
@Override public Map<PartOfSpeechType, ArrayList<Word>> getPartOfSpeechWordMap() { return Collections.unmodifiableMap(partOfSpeechWordMap); }
From source file:com.jayway.restassured.config.HttpClientConfig.java
/** * @return The configured parameters */ public Map<String, ?> params() { return Collections.unmodifiableMap(httpClientParams); }