Spring Framework MultiValueMap - top ranked examples from Open Source projects

These code examples were ranked by Codota’s semantic indexing as the best open source examples for Spring Framework MultiValueMap class.

This code example shows how to use the following methods:getFirst
		return this.multipartFiles.keySet().iterator();
	} 
 
	@Override 
	public MultipartFile getFile(String name) {
		return this.multipartFiles.getFirst(name);
	} 
 
	@Override 
	public List<MultipartFile> getFiles(String name) {
		List<MultipartFile> multipartFiles = this.multipartFiles.get(name);
		if (multipartFiles != null) {
			return multipartFiles;
		} 
		else { 
			return Collections.emptyList();
		} 
	} 
 
	@Override 
6
CodeRank
Connect your IDE to all the code out there  Get Codota for Java
This code example shows how to use the following methods:getFirst
		return getMultipartFiles().keySet().iterator();
	} 
 
	@Override 
	public MultipartFile getFile(String name) {
		return getMultipartFiles().getFirst(name);
	} 
 
	@Override 
	public List<MultipartFile> getFiles(String name) {
		List<MultipartFile> multipartFiles = getMultipartFiles().get(name);
		if (multipartFiles != null) {
			return multipartFiles;
		} 
		else { 
			return Collections.emptyList();
		} 
	} 
 
	@Override 
5
CodeRank
Connect your IDE to all the code out there  Get Codota for Java
This code example shows how to use the following methods:add
	 * form is taken from the {@link MultipartFile#getName()}. 
	 * @param file multipart file to be added 
	 */ 
	public void addFile(MultipartFile file) { 
		Assert.notNull(file, "MultipartFile must not be null"); 
		this.multipartFiles.add(file.getName(), file); 
	} 
 
	@Override 
	public Iterator<String> getFileNames() { 
		return this.multipartFiles.keySet().iterator(); 
	} 
 
	@Override 
	public MultipartFile getFile(String name) { 
		return this.multipartFiles.getFirst(name); 
	} 
 
	@Override 
	public List<MultipartFile> getFiles(String name) { 
5
CodeRank
Connect your IDE to all the code out there  Get Codota for Java
This code example shows how to use the following methods:getFirst
		String[] values = getMultipartParameters().get(name);
		if (values != null) {
			return (values.length > 0 ? values[0] : null);
		} 
		return super.getParameter(name);
	} 
 
	@Override 
	public String[] getParameterValues(String name) {
		String[] values = getMultipartParameters().get(name);
		if (values != null) {
			return values;
		} 
		return super.getParameterValues(name);
	} 
 
	@Override 
	public Enumeration<String> getParameterNames() {
		Map<String, String[]> multipartParameters = getMultipartParameters();
		if (multipartParameters.isEmpty()) {
5
CodeRank
Connect your IDE to all the code out there  Get Codota for Java
This code example shows how to use the following methods:clear, putAll
	/** 
	 * Set the URI scheme-specific-part. When invoked, this method overwrites 
	 * {@linkplain #userInfo(String) user-info}, {@linkplain #host(String) host}, 
	 * {@linkplain #port(int) port}, {@linkplain #path(String) path}, and 
	 * {@link #query(String) query}. 
	 * @param ssp the URI scheme-specific-part, may contain URI template parameters 
	 * @return this UriComponentsBuilder 
	 */ 
	public UriComponentsBuilder schemeSpecificPart(String ssp) {
		this.ssp = ssp;
		resetHierarchicalComponents(); 
		return this;
	} 
 
	/** 
	 * Set the URI user info. The given user info may contain URI template variables, 
	 * and may also be {@code null} to clear the user info of this builder. 
	 * @param userInfo the URI user info 
	 * @return this UriComponentsBuilder 
	 */ 
4
CodeRank
Connect your IDE to all the code out there  Get Codota for Java
See Code Examples for Spring Framework MultiValueMap Methods: