home *** CD-ROM | disk | FTP | other *** search
/ PC Pro 1999 April / DPPCPRO0499.ISO / April / Notes / 50b2wic.exe / DATA1.CAB / NotesProgramFilesJavaSupport / rt.jar / java / security / Provider.class (.txt) < prev    next >
Encoding:
Java Class File  |  1998-04-23  |  1.6 KB  |  58 lines

  1. package java.security;
  2.  
  3. import java.util.Properties;
  4.  
  5. public abstract class Provider extends Properties {
  6.    private String name;
  7.    private String info;
  8.    private double version;
  9.  
  10.    protected Provider(String var1, double var2, String var4) {
  11.       this.name = var1;
  12.       this.version = var2;
  13.       this.info = var4;
  14.    }
  15.  
  16.    Provider(String var1) {
  17.       this(var1, (double)1.0F, "no information available");
  18.    }
  19.  
  20.    public String getName() {
  21.       return this.name;
  22.    }
  23.  
  24.    public double getVersion() {
  25.       return this.version;
  26.    }
  27.  
  28.    public String getInfo() {
  29.       return this.info;
  30.    }
  31.  
  32.    static Provider loadProvider(String var0) {
  33.       try {
  34.          Class var1 = Class.forName(var0);
  35.          Object var2 = var1.newInstance();
  36.          if (var2 instanceof Provider) {
  37.             return (Provider)var2;
  38.          }
  39.       } catch (Exception var3) {
  40.          debug("error loading provider " + var0, var3);
  41.       }
  42.  
  43.       return null;
  44.    }
  45.  
  46.    public String toString() {
  47.       return this.name + " version " + this.version;
  48.    }
  49.  
  50.    private static void debug(String var0) {
  51.       Security.debug(var0);
  52.    }
  53.  
  54.    private static void debug(String var0, Throwable var1) {
  55.       Security.debug(var0, var1);
  56.    }
  57. }
  58.