Samoa instances from weka instances.

@param instances the instances
@return the instances
765111
public Instances samoaInstances(weka.core.Instances instances) {
        Instances samoaInstances = samoaInstancesInformation(instances);
        //We assume that we have only one samoaInstanceInformation for WekaToSamoaInstanceConverter
        this.samoaInstanceInformation = samoaInstances;
        for (int i = 0; i < instances.numInstances(); i++) {
            samoaInstances.add(samoaInstance(instances.instance(i)));
        }
        return samoaInstances;
    }
1351479
public java.util.List<ReservedInstances> getReservedInstances() {
        if (reservedInstances == null) {
            reservedInstances = new com.amazonaws.internal.SdkInternalList<ReservedInstances>();
        }
        return reservedInstances;
    }
350495
public java.util.List<InstanceSummary> getInstancesSummary() {
        if (instancesSummary == null) {
            instancesSummary = new com.amazonaws.internal.SdkInternalList<InstanceSummary>();
        }
        return instancesSummary;
    }
1291707
public List<Object> stepsInstances(List<CandidateSteps> candidateSteps) {
        List<Object> instances = new ArrayList<>();
        for (CandidateSteps steps : candidateSteps) {
            if (steps instanceof Steps) {
                instances.add(((Steps) steps).instance());
            }
        }
        return instances;
    }
1344460
public Stream<LabelledInstance> instances() throws IOException {
        if (single()) {
            return Collections.singletonList(instance(new File(instance))).stream();
        }

        @SuppressWarnings("resource")
        Stream<String> s = Files.lines(Paths.get(instances), StandardCharsets.UTF_8);
        return s.map(x -> instance(new File(x)));
    }
1144371
public Collection<InstanceContextBean> apply( Collection<InstanceContextBean> instances ) {

		final ArrayList<InstanceContextBean> result = new ArrayList<InstanceContextBean> ();
		for( InstanceContextBean instance : instances ) {
			boolean installerMatches = this.installerName == null || this.installerName.equalsIgnoreCase( instance.getInstaller());
			if( installerMatches && this.rootNode.isMatching( instance ))
				result.add( instance );
		}

		result.trimToSize();
		return Collections.unmodifiableCollection(result);
	}
681958
public java.util.List<InstanceState> getInstanceStates() {
        if (instanceStates == null) {
            instanceStates = new com.amazonaws.internal.SdkInternalList<InstanceState>();
        }
        return instanceStates;
    }
202793
public List<V> getAllServicesWithInstance(){
        if(cache == null || cache.size() == 0){
            return Collections.emptyList();
        }
        return Lists.newArrayList(cache.values());
    }
925324
public void setInstanceGroups(java.util.Collection<InstanceGroupDetail> instanceGroups) {
        if (instanceGroups == null) {
            this.instanceGroups = null;
            return;
        }

        this.instanceGroups = new com.amazonaws.internal.SdkInternalList<InstanceGroupDetail>(instanceGroups);
    }
241822
static List<ProviderInfo> convertInstancesToProviders(List<Instance> allInstances) {
        List<ProviderInfo> providerInfos = new ArrayList<ProviderInfo>();
        if (CommonUtils.isEmpty(allInstances)) {
            return providerInfos;
        }

        for (Instance instance : allInstances) {
            String url = convertInstanceToUrl(instance);
            ProviderInfo providerInfo = ProviderHelper.toProviderInfo(url);
            providerInfos.add(providerInfo);
        }
        return providerInfos;
    }
1067853
public java.util.List<String> getInstanceIds() {
        if (instanceIds == null) {
            instanceIds = new com.amazonaws.internal.SdkInternalList<String>();
        }
        return instanceIds;
    }
1325113
public weka.core.Instances wekaInstancesInformation(Instances instances) {
        weka.core.Instances wekaInstances;
        ArrayList<weka.core.Attribute> attInfo = new ArrayList<weka.core.Attribute>();
        for (int i = 0; i < instances.numAttributes(); i++) {
            attInfo.add(wekaAttribute(i, instances.attribute(i)));
        }
        wekaInstances = new weka.core.Instances(instances.getRelationName(), attInfo, 0);
        if (instances.instanceInformation.numOutputAttributes() == 1){
            wekaInstances.setClassIndex(instances.classIndex());
        }
        else {
            //Assign a classIndex to a MultiLabel instance for compatibility reasons
            wekaInstances.setClassIndex(instances.instanceInformation.numOutputAttributes()-1); //instances.numAttributes()-1); //Last
        }
        //System.out.println(attInfo.get(3).name());
        //System.out.println(attInfo.get(3).isNominal());
        //System.out.println(wekaInstances.attribute(3).name());
        //System.out.println(wekaInstances.attribute(3).isNominal());
        return wekaInstances;
    }
1183129
public java.util.List<String> getInstanceTypes() {
        if (instanceTypes == null) {
            instanceTypes = new com.amazonaws.internal.SdkInternalList<String>();
        }
        return instanceTypes;
    }
91710
public java.util.List<InstanceStateChange> getStartingInstances() {
        if (startingInstances == null) {
            startingInstances = new com.amazonaws.internal.SdkInternalList<InstanceStateChange>();
        }
        return startingInstances;
    }
734613
public java.util.List<InstanceInformation> getInstanceInformationList() {
        if (instanceInformationList == null) {
            instanceInformationList = new com.amazonaws.internal.SdkInternalList<InstanceInformation>();
        }
        return instanceInformationList;
    }
529680
public List<String> listInstanceIDs(final Set<String> instanceIDs) {
        Set<String> allInstanceIDs = allMockEc2Instances.keySet();
        if (null == instanceIDs || instanceIDs.size() == 0) {
            return new ArrayList<String>(allInstanceIDs);
        } else {
            List<String> filteredInstanceIDs = new ArrayList<String>();
            for (String id : allInstanceIDs) {
                if (null != id && instanceIDs.contains(id)) {
                    filteredInstanceIDs.add(id);
                }
            }
            return filteredInstanceIDs;
        }
    }
265466
public java.util.List<String> getInstancesToTerminate() {
        if (instancesToTerminate == null) {
            instancesToTerminate = new com.amazonaws.internal.SdkInternalList<String>();
        }
        return instancesToTerminate;
    }