Revision 2618
Added by Jing Tao about 19 years ago
src/edu/ucsb/nceas/metacat/Eml200SAXHandler.java | ||
---|---|---|
681 | 681 |
MetaCatUtil.debugMessage("DOCTYPE-b: " + doctype, 30); |
682 | 682 |
} |
683 | 683 |
rootNode.writeNodename(docname); |
684 |
System.out.println("here!!!!!!!!!!!!!!!!!!1"); |
|
684 |
//System.out.println("here!!!!!!!!!!!!!!!!!!1");
|
|
685 | 685 |
try { |
686 | 686 |
// for validated XML Documents store a reference to XML DB |
687 | 687 |
// Catalog |
... | ... | |
711 | 711 |
catalogid = rs.getString(1); |
712 | 712 |
} |
713 | 713 |
stmt.close(); |
714 |
System.out.println("here!!!!!!!!!!!!!!!!!!2"); |
|
714 |
//System.out.println("here!!!!!!!!!!!!!!!!!!2");
|
|
715 | 715 |
}//try |
716 | 716 |
finally { |
717 | 717 |
// Return dbconnection |
... | ... | |
837 | 837 |
// described element. If it has a descirbed element, |
838 | 838 |
// this code would hurt any thing |
839 | 839 |
processAdditionalAccess = true; |
840 |
System.out.println("assing process addtional access true when meet access");
|
|
840 |
MetaCatUtil.debugMessage("assing process addtional access true when meet access", 20);
|
|
841 | 841 |
} |
842 | 842 |
|
843 | 843 |
|
... | ... | |
938 | 938 |
localName, prefix, MetaCatUtil.normalize(null)); |
939 | 939 |
storedAccessNodeStack.push(nodeElement); |
940 | 940 |
processAdditionalAccess = true; |
941 |
System.out.println("set processAdditonalAccess ture when meet describe");
|
|
941 |
MetaCatUtil.debugMessage("set processAdditonalAccess ture when meet describe", 20);
|
|
942 | 942 |
} |
943 | 943 |
else if (inAddtionalMetaData && processAdditionalAccess && |
944 | 944 |
parentNode.getTagName().equals(ADDITIONALMETADATA) && |
... | ... | |
954 | 954 |
// If additionalMetadata has access element, the flag will be |
955 | 955 |
// terminated in endElement |
956 | 956 |
processAdditionalAccess = false; |
957 |
System.out.println("set processAddtionAccess false if the there is no access in additional");
|
|
957 |
MetaCatUtil.debugMessage("set processAddtionAccess false if the there is no access in additional", 20);
|
|
958 | 958 |
} |
959 | 959 |
else if (currentNode.getTagName().equals(DISTRIBUTION) && |
960 | 960 |
!inAddtionalMetaData) |
... | ... | |
1817 | 1817 |
deleteAccessSubTreeRecord(docid); |
1818 | 1818 |
//write additional access rule, and old records in xml_access will be |
1819 | 1819 |
//deleted too |
1820 |
System.out.println("before write additional access rules"); |
|
1820 |
//System.out.println("before write additional access rules");
|
|
1821 | 1821 |
writeAddtionalAccessRuleToDB(); |
1822 |
System.out.println("after write additional access rules"); |
|
1822 |
//System.out.println("after write additional access rules");
|
|
1823 | 1823 |
//write top leve access rule, and old records in xml_access will be |
1824 | 1824 |
//deleted too |
1825 | 1825 |
|
1826 | 1826 |
if (topAccessSection != null){ |
1827 | 1827 |
writeTopLevelAccessRuleToDB(); |
1828 | 1828 |
} |
1829 |
System.out.println("after write top access rules"); |
|
1829 |
//System.out.println("after write top access rules");
|
|
1830 | 1830 |
}//writeAccessRuleToDB |
1831 | 1831 |
|
1832 | 1832 |
|
... | ... | |
1943 | 1943 |
*/ |
1944 | 1944 |
private void writeAddtionalAccessRuleToDB() throws SAXException |
1945 | 1945 |
{ |
1946 |
System.out.println("in write addtional"); |
|
1946 |
//System.out.println("in write addtional");
|
|
1947 | 1947 |
// we should delete all inline access rules in xml_access if |
1948 | 1948 |
// user has all permission |
1949 | 1949 |
if (!needCheckingAccessModule) |
... | ... | |
1952 | 1952 |
} |
1953 | 1953 |
for (int i=0; i < addtionalAccessVector.size(); i++) |
1954 | 1954 |
{ |
1955 |
System.out.println("in for loop of write addtional"); |
|
1955 |
//System.out.println("in for loop of write addtional");
|
|
1956 | 1956 |
AccessSection access = (AccessSection)addtionalAccessVector.elementAt(i); |
1957 | 1957 |
Vector describeIdList = access.getDescribedIdList(); |
1958 | 1958 |
// if this access is a reference, a new access object will be created |
... | ... | |
2028 | 2028 |
{ |
2029 | 2029 |
// if top access is reference, we need figure out the real access rules |
2030 | 2030 |
// it points to |
2031 |
System.out.println("permorder in top level" + topAccessSection.getPermissionOrder()); |
|
2031 |
//System.out.println("permorder in top level" + topAccessSection.getPermissionOrder());
|
|
2032 | 2032 |
AccessSection newAccess = resolveAccessRuleReference(topAccessSection); |
2033 |
System.out.println("permorder in new level" + newAccess.getPermissionOrder()); |
|
2033 |
//System.out.println("permorder in new level" + newAccess.getPermissionOrder());
|
|
2034 | 2034 |
String permOrder = newAccess.getPermissionOrder(); |
2035 | 2035 |
Vector accessRule = newAccess.getAccessRules(); |
2036 | 2036 |
String subtree = null; |
Also available in: Unified diff
Remove the print out statement.