Revision 9583
Added by Jing Tao about 8 years ago
DocumentImplWrapper.java | ||
---|---|---|
59 | 59 |
}//Constructor |
60 | 60 |
|
61 | 61 |
public String write(DBConnection conn, String xml, String pub, Reader dtd, |
62 |
String action, String docid, String user, String[] groups, byte[]xmlBytes) throws Exception { |
|
62 |
String action, String docid, String user, String[] groups, byte[]xmlBytes, String formatId) throws Exception {
|
|
63 | 63 |
return DocumentImpl.write(conn, xml, pub, dtd, action, docid, user, groups, |
64 |
ruleBase, needValidation, writeAccessRules, xmlBytes); |
|
64 |
ruleBase, needValidation, writeAccessRules, xmlBytes, formatId);
|
|
65 | 65 |
} |
66 | 66 |
|
67 | 67 |
public String writeReplication(DBConnection conn, String xml, byte[]xmlBytes, String pub, Reader dtd, |
68 | 68 |
String action, String accnum, String user, String[] groups, |
69 |
String homeServer, String notifyServer, Date createDate, Date updateDate) |
|
69 |
String homeServer, String notifyServer, Date createDate, Date updateDate, String formatId)
|
|
70 | 70 |
throws Exception { |
71 | 71 |
//we don't need to check validation in replication |
72 | 72 |
// so rule base is null and need validation is false (first false) |
... | ... | |
74 | 74 |
// and timed replication is false (last false) |
75 | 75 |
return DocumentImpl.writeReplication(conn, xml, xmlBytes, pub, dtd, action, accnum, user, |
76 | 76 |
groups, homeServer, notifyServer, ruleBase, false, |
77 |
DocumentImpl.DOCUMENTTABLE, false, createDate, updateDate); |
|
77 |
DocumentImpl.DOCUMENTTABLE, false, createDate, updateDate, formatId);
|
|
78 | 78 |
// last false means is not timed replication |
79 | 79 |
|
80 | 80 |
} |
... | ... | |
99 | 99 |
public String writeReplication(DBConnection conn, String xml, byte[]xmlBytes, String pub, Reader dtd, |
100 | 100 |
String action, String accnum, String user, String[] groups, |
101 | 101 |
String homeServer, String notifyServer, String tableName, |
102 |
boolean timedReplication, Date createDate, Date updateDate) |
|
102 |
boolean timedReplication, Date createDate, Date updateDate, String formatId)
|
|
103 | 103 |
throws Exception { |
104 | 104 |
//we don't need to check validation in replication |
105 | 105 |
// so rule base is null and need validation is false |
106 | 106 |
return DocumentImpl.writeReplication(conn, xml, xmlBytes, pub, dtd, action, accnum, user, |
107 | 107 |
groups, homeServer, notifyServer, ruleBase, false, tableName, |
108 |
timedReplication, createDate, updateDate); |
|
108 |
timedReplication, createDate, updateDate, formatId);
|
|
109 | 109 |
} |
110 | 110 |
|
111 | 111 |
} |
Also available in: Unified diff
If a format id in the system metadata is registered in the xml_catalog table, we will use the schema location for the format id to validate the xml instance;
otherwise, we will use our previous way.