All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.openstack4j.openstack.common.ListResult Maven / Gradle / Ivy

package org.openstack4j.openstack.common;

import java.util.Collections;
import java.util.List;

import org.openstack4j.core.transport.ListType;
import org.openstack4j.model.ModelEntity;

/**
 * A List result which wrappers a JSON Array
 *
 * @param  the generic type
 */
public abstract class ListResult implements ModelEntity, ListType {

	private static final long serialVersionUID = 1L;

	protected abstract List value();
	
	public List getList() {
		if (value() == null)
			return Collections.emptyList();
		return value();
	}

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy