Here you can find the source of constructFilter(String hostname, Vector schedulertypes)
Parameter | Description |
---|---|
hostname | specifies the hostname |
schedulertypes | a parameter |
private static String constructFilter(String hostname, Vector schedulertypes)
//package com.java2s; /*// w w w . ja va 2 s . c om * Portions of this file Copyright 1999-2005 University of Chicago * Portions of this file Copyright 1999-2005 The University of Southern California. * * This file or a portion of this file is licensed under the * terms of the Globus Toolkit Public License, found at * http://www.globus.org/toolkit/download/license.html. * If you redistribute this file, with or without * modifications, you must include this notice in the file. */ import java.util.*; public class Main { /** what is this used for? * * @param hostname specifies the hostname * @param schedulertypes */ private static String constructFilter(String hostname, Vector schedulertypes) { StringBuffer filter = new StringBuffer(); filter.append("(&(objectclass=GlobusServiceJobManager)(hn="); filter.append(hostname); if (hostname.indexOf("*") == -1) filter.append("*"); filter.append(")"); int size = schedulertypes.size(); if (size != 0) { filter.append("(|"); for (int i = 0; i < size; i++) { filter.append("(schedulertype="); filter.append(schedulertypes.elementAt(i)); filter.append(")"); } filter.append(")"); } filter.append(")"); return filter.toString(); } }