1 11 package org.eclipse.update.internal.configurator; 12 13 import org.eclipse.update.configurator.*; 14 import org.eclipse.update.configurator.IPlatformConfiguration.*; 15 16 17 public class SitePolicy implements IPlatformConfiguration.ISitePolicy { 18 19 private int type; 20 private String [] list; 21 22 public SitePolicy() { 23 } 24 public SitePolicy(int type, String [] list) { 25 if (type != ISitePolicy.USER_INCLUDE && type != ISitePolicy.USER_EXCLUDE && type != ISitePolicy.MANAGED_ONLY) 26 throw new IllegalArgumentException (); 27 this.type = type; 28 29 if (list == null) 30 this.list = new String [0]; 31 else 32 this.list = list; 33 } 34 35 38 public int getType() { 39 return type; 40 } 41 42 45 public String [] getList() { 46 return list; 47 } 48 49 52 public synchronized void setList(String [] list) { 53 if (list == null) 54 this.list = new String [0]; 55 else 56 this.list = list; 57 } 58 59 } 60 | Popular Tags |