Java Doc for AlgorithmId.java in  » 6.0-JDK-Modules » j2me » sun » security » x509 » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » 6.0 JDK Modules » j2me » sun.security.x509 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


java.lang.Object
   sun.security.x509.AlgorithmId

All known Subclasses:   sun.security.x509.AlgIdDSA,
AlgorithmId
public class AlgorithmId implements Serializable,DerEncoder(Code)
This class identifies algorithms, such as cryptographic transforms, each of which may be associated with parameters. Instances of this base class are used when this runtime environment has no special knowledge of the algorithm type, and may also be used in other cases. Equivalence is defined according to OID and (where relevant) parameters.

Subclasses may be used, for example when when the algorithm ID has associated parameters which some code (e.g. code using public keys) needs to have parsed. Two examples of such algorithms are Diffie-Hellman key exchange, and the Digital Signature Standard Algorithm (DSS/DSA).

The OID constants defined in this class correspond to some widely used algorithms, for which conventional string names have been defined. This class is not a general repository for OIDs, or for such string names. Note that the mappings between algorithm IDs and algorithm names is not one-to-one.
version:
   1.84
author:
   David Brownell
author:
   Amit Kapoor
author:
   Hemma Prafullchandra



Field Summary
public static  ObjectIdentifierDH_PKIX_oid
    
public static  ObjectIdentifierDH_oid
    
public static  ObjectIdentifierDSA_OIW_oid
    
public static  ObjectIdentifierDSA_oid
    
public static  ObjectIdentifierMD2_oid
    
public static  ObjectIdentifierMD5_oid
    
public static  ObjectIdentifierRSAEncryption_oid
    
public static  ObjectIdentifierRSA_oid
    
public static  ObjectIdentifierSHA1_OIW_oid
    
public static  ObjectIdentifierSHA5_oid
    
public static  ObjectIdentifierSHA_oid
    
public static  ObjectIdentifiermd2WithRSAEncryption_oid
    
public static  ObjectIdentifiermd5WithRSAEncryption_oid
    
protected  DerValueparams
     Parameters for this algorithm.
public static  ObjectIdentifiersha1WithDSA_OIW_oid
    
public static  ObjectIdentifiersha1WithDSA_oid
    
public static  ObjectIdentifiersha1WithRSAEncryption_OIW_oid
    
public static  ObjectIdentifiersha1WithRSAEncryption_oid
    
public static  ObjectIdentifiershaWithDSA_OIW_oid
    

Constructor Summary
public  AlgorithmId(ObjectIdentifier oid)
     Constructs a parameterless algorithm ID.
public  AlgorithmId(ObjectIdentifier oid, AlgorithmParameters algparams)
     Constructs an algorithm ID with algorithm parameters.
public  AlgorithmId()
     Constructs an algorithm ID which will be initialized separately, for example by deserialization.

Method Summary
protected  voiddecodeParams()
    
public  voidderEncode(OutputStream out)
     DER encode this object onto an output stream.
final public  voidencode(DerOutputStream out)
     Marshal a DER-encoded "AlgorithmID" sequence on the DER stream.
final public  byte[]encode()
     Returns the DER-encoded X.509 AlgorithmId as a byte array.
public  booleanequals(AlgorithmId other)
     Returns true iff the argument indicates the same algorithm with the same parameters.
public  booleanequals(Object other)
     Compares this AlgorithmID to another.
final public  booleanequals(ObjectIdentifier id)
     Compares two algorithm IDs for equality.
public static  AlgorithmIdget(String algname)
     Returns one of the algorithm IDs most commonly associated with this algorithm name.
public static  AlgorithmIdget(AlgorithmParameters algparams)
     Returns one of the algorithm IDs most commonly associated with this algorithm parameters.
public static  AlgorithmIdgetAlgorithmId(String algname)
     Returns one of the algorithm IDs most commonly associated with this algorithm name.
public  byte[]getEncodedParams()
     Returns the DER encoded parameter, which can then be used to initialize java.security.AlgorithmParamters.
public  StringgetName()
     Returns a name for the algorithm which may be more intelligible to humans than the algorithm's OID, but which won't necessarily be comprehensible on other systems.
final public  ObjectIdentifiergetOID()
     Returns the ISO OID for this algorithm.
public  AlgorithmParametersgetParameters()
    
public  inthashCode()
     Returns a hashcode for this AlgorithmId.
protected  StringparamsToString()
     Provides a human-readable description of the algorithm parameters.
public static  AlgorithmIdparse(DerValue val)
     Parse (unmarshal) an ID from a DER sequence input value.
public  StringtoString()
     Returns a string describing the algorithm and its parameters.

Field Detail
DH_PKIX_oid
public static ObjectIdentifier DH_PKIX_oid(Code)



DH_oid
public static ObjectIdentifier DH_oid(Code)



DSA_OIW_oid
public static ObjectIdentifier DSA_OIW_oid(Code)



DSA_oid
public static ObjectIdentifier DSA_oid(Code)



MD2_oid
public static ObjectIdentifier MD2_oid(Code)



MD5_oid
public static ObjectIdentifier MD5_oid(Code)



RSAEncryption_oid
public static ObjectIdentifier RSAEncryption_oid(Code)



RSA_oid
public static ObjectIdentifier RSA_oid(Code)



SHA1_OIW_oid
public static ObjectIdentifier SHA1_OIW_oid(Code)



SHA5_oid
public static ObjectIdentifier SHA5_oid(Code)



SHA_oid
public static ObjectIdentifier SHA_oid(Code)



md2WithRSAEncryption_oid
public static ObjectIdentifier md2WithRSAEncryption_oid(Code)



md5WithRSAEncryption_oid
public static ObjectIdentifier md5WithRSAEncryption_oid(Code)



params
protected DerValue params(Code)
Parameters for this algorithm. These are stored in unparsed DER-encoded form; subclasses can be made to automaticaly parse them so there is fast access to these parameters.



sha1WithDSA_OIW_oid
public static ObjectIdentifier sha1WithDSA_OIW_oid(Code)



sha1WithDSA_oid
public static ObjectIdentifier sha1WithDSA_oid(Code)



sha1WithRSAEncryption_OIW_oid
public static ObjectIdentifier sha1WithRSAEncryption_OIW_oid(Code)



sha1WithRSAEncryption_oid
public static ObjectIdentifier sha1WithRSAEncryption_oid(Code)



shaWithDSA_OIW_oid
public static ObjectIdentifier shaWithDSA_OIW_oid(Code)




Constructor Detail
AlgorithmId
public AlgorithmId(ObjectIdentifier oid)(Code)
Constructs a parameterless algorithm ID.
Parameters:
  oid - the identifier for the algorithm



AlgorithmId
public AlgorithmId(ObjectIdentifier oid, AlgorithmParameters algparams)(Code)
Constructs an algorithm ID with algorithm parameters.
Parameters:
  oid - the identifier for the algorithm.
Parameters:
  algparams - the associated algorithm parameters.



AlgorithmId
public AlgorithmId()(Code)
Constructs an algorithm ID which will be initialized separately, for example by deserialization.




Method Detail
decodeParams
protected void decodeParams() throws IOException(Code)



derEncode
public void derEncode(OutputStream out) throws IOException(Code)
DER encode this object onto an output stream. Implements the DerEncoder interface.
Parameters:
  out - the output stream on which to write the DER encoding.
exception:
  IOException - on encoding error.



encode
final public void encode(DerOutputStream out) throws IOException(Code)
Marshal a DER-encoded "AlgorithmID" sequence on the DER stream.



encode
final public byte[] encode() throws IOException(Code)
Returns the DER-encoded X.509 AlgorithmId as a byte array.



equals
public boolean equals(AlgorithmId other)(Code)
Returns true iff the argument indicates the same algorithm with the same parameters.



equals
public boolean equals(Object other)(Code)
Compares this AlgorithmID to another. If algorithm parameters are available, they are compared. Otherwise, just the object IDs for the algorithm are compared.
Parameters:
  other - preferably an AlgorithmId, else an ObjectIdentifier



equals
final public boolean equals(ObjectIdentifier id)(Code)
Compares two algorithm IDs for equality. Returns true iff they are the same algorithm, ignoring algorithm parameters.



get
public static AlgorithmId get(String algname) throws NoSuchAlgorithmException(Code)
Returns one of the algorithm IDs most commonly associated with this algorithm name.
Parameters:
  algname - the name being used
exception:
  NoSuchAlgorithmException - on error.



get
public static AlgorithmId get(AlgorithmParameters algparams) throws NoSuchAlgorithmException(Code)
Returns one of the algorithm IDs most commonly associated with this algorithm parameters.
Parameters:
  algparams - the associated algorithm parameters.
exception:
  NoSuchAlgorithmException - on error.



getAlgorithmId
public static AlgorithmId getAlgorithmId(String algname) throws NoSuchAlgorithmException(Code)
Returns one of the algorithm IDs most commonly associated with this algorithm name.
Parameters:
  algname - the name being used
exception:
  NoSuchAlgorithmException - on error.



getEncodedParams
public byte[] getEncodedParams() throws IOException(Code)
Returns the DER encoded parameter, which can then be used to initialize java.security.AlgorithmParamters. DER encoded parameters, or null not present.



getName
public String getName()(Code)
Returns a name for the algorithm which may be more intelligible to humans than the algorithm's OID, but which won't necessarily be comprehensible on other systems. For example, this might return a name such as "MD5withRSA" for a signature algorithm on some systems. It also returns names like "OID.1.2.3.4", when no particular name for the algorithm is known.



getOID
final public ObjectIdentifier getOID()(Code)
Returns the ISO OID for this algorithm. This is usually converted to a string and used as part of an algorithm name, for example "OID.1.3.14.3.2.13" style notation. Use the getName call when you do not need to ensure cross-system portability of algorithm names, or need a user friendly name.



getParameters
public AlgorithmParameters getParameters()(Code)



hashCode
public int hashCode()(Code)
Returns a hashcode for this AlgorithmId. a hashcode for this AlgorithmId.



paramsToString
protected String paramsToString()(Code)
Provides a human-readable description of the algorithm parameters. This may be redefined by subclasses which parse those parameters.



parse
public static AlgorithmId parse(DerValue val) throws IOException(Code)
Parse (unmarshal) an ID from a DER sequence input value. This form parsing might be used when expanding a value which has already been partially unmarshaled as a set or sequence member.
exception:
  IOException - on error.
Parameters:
  val - the input value, which contains the algid and, ifthere are any parameters, those parameters. an ID for the algorithm. If the system is configuredappropriately, this may be an instance of a classwith some kind of special support for this algorithm.In that case, you may "narrow" the type of the ID.



toString
public String toString()(Code)
Returns a string describing the algorithm and its parameters.



Methods inherited from java.lang.Object
public boolean equals(Object obj)(Code)(Java Doc)
final native public Class getClass()(Code)(Java Doc)
native public int hashCode()(Code)(Java Doc)
final native public void notify()(Code)(Java Doc)
final native public void notifyAll()(Code)(Java Doc)
public String toString()(Code)(Java Doc)
final native public void wait(long timeout) throws InterruptedException(Code)(Java Doc)
final public void wait(long timeout, int nanos) throws InterruptedException(Code)(Java Doc)
final public void wait() throws InterruptedException(Code)(Java Doc)

www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.