Source Code Cross Referenced for PKIXPolicyNode.java in  » Security » Bouncy-Castle » org » bouncycastle » jce » provider » 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 » Security » Bouncy Castle » org.bouncycastle.jce.provider 
Source Cross Referenced  Class Diagram Java Document (Java Doc) 


001:        package org.bouncycastle.jce.provider;
002:
003:        import java.security.cert.PolicyNode;
004:        import java.util.ArrayList;
005:        import java.util.HashSet;
006:        import java.util.Iterator;
007:        import java.util.List;
008:        import java.util.Set;
009:
010:        public class PKIXPolicyNode implements  PolicyNode {
011:            protected List children;
012:            protected int depth;
013:            protected Set expectedPolicies;
014:            protected PolicyNode parent;
015:            protected Set policyQualifiers;
016:            protected String validPolicy;
017:            protected boolean critical;
018:
019:            /*  
020:             *  
021:             *  CONSTRUCTORS
022:             *  
023:             */
024:
025:            public PKIXPolicyNode(List _children, int _depth,
026:                    Set _expectedPolicies, PolicyNode _parent,
027:                    Set _policyQualifiers, String _validPolicy,
028:                    boolean _critical) {
029:                children = _children;
030:                depth = _depth;
031:                expectedPolicies = _expectedPolicies;
032:                parent = _parent;
033:                policyQualifiers = _policyQualifiers;
034:                validPolicy = _validPolicy;
035:                critical = _critical;
036:            }
037:
038:            public void addChild(PKIXPolicyNode _child) {
039:                children.add(_child);
040:                _child.setParent(this );
041:            }
042:
043:            public Iterator getChildren() {
044:                return children.iterator();
045:            }
046:
047:            public int getDepth() {
048:                return depth;
049:            }
050:
051:            public Set getExpectedPolicies() {
052:                return expectedPolicies;
053:            }
054:
055:            public PolicyNode getParent() {
056:                return parent;
057:            }
058:
059:            public Set getPolicyQualifiers() {
060:                return policyQualifiers;
061:            }
062:
063:            public String getValidPolicy() {
064:                return validPolicy;
065:            }
066:
067:            public boolean hasChildren() {
068:                return !children.isEmpty();
069:            }
070:
071:            public boolean isCritical() {
072:                return critical;
073:            }
074:
075:            public void removeChild(PKIXPolicyNode _child) {
076:                children.remove(_child);
077:            }
078:
079:            public void setCritical(boolean _critical) {
080:                critical = _critical;
081:            }
082:
083:            public void setParent(PKIXPolicyNode _parent) {
084:                parent = _parent;
085:            }
086:
087:            public String toString() {
088:                return toString("");
089:            }
090:
091:            public String toString(String _indent) {
092:                StringBuffer _buf = new StringBuffer();
093:                _buf.append(_indent);
094:                _buf.append(validPolicy);
095:                _buf.append(" {\n");
096:
097:                for (int i = 0; i < children.size(); i++) {
098:                    _buf.append(((PKIXPolicyNode) children.get(i))
099:                            .toString(_indent + "    "));
100:                }
101:
102:                _buf.append(_indent);
103:                _buf.append("}\n");
104:                return _buf.toString();
105:            }
106:
107:            public Object clone() {
108:                return copy();
109:            }
110:
111:            public PKIXPolicyNode copy() {
112:                Set _expectedPolicies = new HashSet();
113:                Iterator _iter = expectedPolicies.iterator();
114:                while (_iter.hasNext()) {
115:                    _expectedPolicies.add(new String((String) _iter.next()));
116:                }
117:
118:                Set _policyQualifiers = new HashSet();
119:                _iter = policyQualifiers.iterator();
120:                while (_iter.hasNext()) {
121:                    _policyQualifiers.add(new String((String) _iter.next()));
122:                }
123:
124:                PKIXPolicyNode _node = new PKIXPolicyNode(new ArrayList(),
125:                        depth, _expectedPolicies, null, _policyQualifiers,
126:                        new String(validPolicy), critical);
127:
128:                _iter = children.iterator();
129:                while (_iter.hasNext()) {
130:                    PKIXPolicyNode _child = ((PKIXPolicyNode) _iter.next())
131:                            .copy();
132:                    _child.setParent(_node);
133:                    _node.addChild(_child);
134:                }
135:
136:                return _node;
137:            }
138:        }
www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.