本文整理匯總了Java中org.zendesk.client.v2.model.Audit類的典型用法代碼示例。如果您正苦於以下問題:Java Audit類的具體用法?Java Audit怎麽用?Java Audit使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。
Audit類屬於org.zendesk.client.v2.model包,在下文中一共展示了Audit類的9個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。
示例1: addAudit
import org.zendesk.client.v2.model.Audit; //導入依賴的package包/類
void addAudit( Audit audit ) throws KettleValueException {
if ( auditSummaries == null ) {
auditSummaries = new LinkedMap<Long, ZendeskTicketAuditHistory>();
}
if ( auditSummaries.size() <= 0 ) {
auditSummaries.put( audit.getId(), new ZendeskTicketAuditHistory( audit ) );
} else {
try {
ZendeskTicketAuditHistory newAudit =
auditSummaries.get( auditSummaries.lastKey() ).createNextAudit( audit, auditSummaries );
auditSummaries.put( audit.getId(), newAudit );
} catch ( CloneNotSupportedException e ) {
e.printStackTrace();
}
}
}
示例2: ZendeskTicketAuditHistory
import org.zendesk.client.v2.model.Audit; //導入依賴的package包/類
public ZendeskTicketAuditHistory( Audit audit ) throws KettleValueException {
this.ticketId = audit.getTicketId();
this.auditId = audit.getId();
this.createdTime = audit.getCreatedAt();
this.customFields = new LinkedHashMap<String, String>();
this.processEvents( audit.getEvents(), null );
}
示例3: createNextAudit
import org.zendesk.client.v2.model.Audit; //導入依賴的package包/類
public ZendeskTicketAuditHistory createNextAudit( Audit audit, AbstractLinkedMap<Long, ZendeskTicketAuditHistory> auditSummaries ) throws CloneNotSupportedException, KettleValueException {
ZendeskTicketAuditHistory nextAudit = (ZendeskTicketAuditHistory) this.clone();
nextAudit.auditId = audit.getId();
nextAudit.createdTime = audit.getCreatedAt();
nextAudit.processEvents( audit.getEvents(), auditSummaries );
return nextAudit;
}
示例4: getTicketAudits
import org.zendesk.client.v2.model.Audit; //導入依賴的package包/類
@Test
public void getTicketAudits() throws Exception {
createClientWithTokenOrPassword();
for (Audit a : instance.getTicketAudits(1L)) {
assertThat(a, notNullValue());
assertThat(a.getEvents(), not(Collections.<Event>emptyList()));
}
}
示例5: getTicketAudits
import org.zendesk.client.v2.model.Audit; //導入依賴的package包/類
public Iterable<Audit> getTicketAudits(Ticket ticket) {
checkHasId(ticket);
return getTicketAudits(ticket.getId());
}
示例6: getTicketAudit
import org.zendesk.client.v2.model.Audit; //導入依賴的package包/類
public Audit getTicketAudit(Ticket ticket, Audit audit) {
checkHasId(audit);
return getTicketAudit(ticket, audit.getId());
}
示例7: trustTicketAudit
import org.zendesk.client.v2.model.Audit; //導入依賴的package包/類
public void trustTicketAudit(Ticket ticket, Audit audit) {
checkHasId(audit);
trustTicketAudit(ticket, audit.getId());
}
示例8: makePrivateTicketAudit
import org.zendesk.client.v2.model.Audit; //導入依賴的package包/類
public void makePrivateTicketAudit(Ticket ticket, Audit audit) {
checkHasId(audit);
makePrivateTicketAudit(ticket, audit.getId());
}
示例9: checkHasId
import org.zendesk.client.v2.model.Audit; //導入依賴的package包/類
private static void checkHasId(Audit audit) {
if (audit.getId() == null) {
throw new IllegalArgumentException("Audit requires id");
}
}