1 7 8 package javax.imageio.spi; 9 10 import java.util.Locale ; 11 import javax.imageio.spi.RegisterableService ; 12 import javax.imageio.spi.ServiceRegistry ; 13 14 28 public abstract class IIOServiceProvider implements RegisterableService { 29 30 35 protected String vendorName; 36 37 42 protected String version; 43 44 56 public IIOServiceProvider(String vendorName, 57 String version) { 58 if (vendorName == null) { 59 throw new IllegalArgumentException ("vendorName == null!"); 60 } 61 if (version == null) { 62 throw new IllegalArgumentException ("version == null!"); 63 } 64 this.vendorName = vendorName; 65 this.version = version; 66 } 67 68 75 public IIOServiceProvider() { 76 } 77 78 93 public void onRegistration(ServiceRegistry registry, 94 Class <?> category) {} 95 96 106 public void onDeregistration(ServiceRegistry registry, 107 Class <?> category) {} 108 109 121 public String getVendorName() { 122 return vendorName; 123 } 124 125 138 public String getVersion() { 139 return version; 140 } 141 142 154 public abstract String getDescription(Locale locale); 155 } 156 | Popular Tags |