From 4c22f5282a53a29252a4c11dbe7034a0c994e633 Mon Sep 17 00:00:00 2001 From: Maxim Date: Tue, 12 Dec 2023 13:05:08 +0300 Subject: [PATCH] Update attributes methods --- .../java/org/verapdf/gf/model/impl/pd/gfse/GFSEFENote.java | 2 +- .../main/java/org/verapdf/gf/model/impl/pd/gfse/GFSEForm.java | 2 +- .../main/java/org/verapdf/gf/model/impl/pd/gfse/GFSEL.java | 2 +- .../main/java/org/verapdf/gf/model/impl/pd/gfse/GFSETD.java | 2 +- .../main/java/org/verapdf/gf/model/impl/pd/gfse/GFSETH.java | 2 +- .../java/org/verapdf/gf/model/impl/pd/gfse/GFSETableCell.java | 4 ++-- .../verapdf/gf/model/impl/sa/GFSAAttributesDictionary.java | 4 ++-- .../org/verapdf/gf/model/impl/sa/structelems/GFSAFigure.java | 2 +- 8 files changed, 10 insertions(+), 10 deletions(-) diff --git a/validation-model/src/main/java/org/verapdf/gf/model/impl/pd/gfse/GFSEFENote.java b/validation-model/src/main/java/org/verapdf/gf/model/impl/pd/gfse/GFSEFENote.java index b37679fa1..82a822b5e 100644 --- a/validation-model/src/main/java/org/verapdf/gf/model/impl/pd/gfse/GFSEFENote.java +++ b/validation-model/src/main/java/org/verapdf/gf/model/impl/pd/gfse/GFSEFENote.java @@ -75,6 +75,6 @@ public GFSEFENote(PDStructElem structElemDictionary) { @Override public String getNoteType() { - return AttributeHelper.getNoteType(simplePDObject); + return AttributeHelper.getNoteType(simpleCOSObject); } } diff --git a/validation-model/src/main/java/org/verapdf/gf/model/impl/pd/gfse/GFSEForm.java b/validation-model/src/main/java/org/verapdf/gf/model/impl/pd/gfse/GFSEForm.java index 8fea7ec6b..b19c0527b 100644 --- a/validation-model/src/main/java/org/verapdf/gf/model/impl/pd/gfse/GFSEForm.java +++ b/validation-model/src/main/java/org/verapdf/gf/model/impl/pd/gfse/GFSEForm.java @@ -41,7 +41,7 @@ public GFSEForm(PDStructElem structElemDictionary) { @Override public String getroleAttribute() { - return AttributeHelper.getRole(this.simplePDObject); + return AttributeHelper.getRole(this.simpleCOSObject); } @Override diff --git a/validation-model/src/main/java/org/verapdf/gf/model/impl/pd/gfse/GFSEL.java b/validation-model/src/main/java/org/verapdf/gf/model/impl/pd/gfse/GFSEL.java index a5c9ee20c..47be8d71d 100644 --- a/validation-model/src/main/java/org/verapdf/gf/model/impl/pd/gfse/GFSEL.java +++ b/validation-model/src/main/java/org/verapdf/gf/model/impl/pd/gfse/GFSEL.java @@ -36,7 +36,7 @@ public GFSEL(PDStructElem structElemDictionary) { @Override public String getListNumbering() { - return AttributeHelper.getListNumbering(simplePDObject); + return AttributeHelper.getListNumbering(simpleCOSObject); } @Override diff --git a/validation-model/src/main/java/org/verapdf/gf/model/impl/pd/gfse/GFSETD.java b/validation-model/src/main/java/org/verapdf/gf/model/impl/pd/gfse/GFSETD.java index 69eaf6dc1..89742d7ce 100644 --- a/validation-model/src/main/java/org/verapdf/gf/model/impl/pd/gfse/GFSETD.java +++ b/validation-model/src/main/java/org/verapdf/gf/model/impl/pd/gfse/GFSETD.java @@ -47,7 +47,7 @@ public GFSETD(PDStructElem structElemDictionary) { } protected List getHeaders() { - COSArray headers = AttributeHelper.getArrayAttributeValue(simplePDObject, ASAtom.HEADERS, + COSArray headers = AttributeHelper.getArrayAttributeValue(simpleCOSObject, ASAtom.HEADERS, TaggedPDFConstants.TABLE, null); if (headers != null) { List list = new LinkedList<>(); diff --git a/validation-model/src/main/java/org/verapdf/gf/model/impl/pd/gfse/GFSETH.java b/validation-model/src/main/java/org/verapdf/gf/model/impl/pd/gfse/GFSETH.java index 1a83e688b..7f984e38a 100644 --- a/validation-model/src/main/java/org/verapdf/gf/model/impl/pd/gfse/GFSETH.java +++ b/validation-model/src/main/java/org/verapdf/gf/model/impl/pd/gfse/GFSETH.java @@ -45,7 +45,7 @@ protected String getTHID() { } protected String getScope() { - return AttributeHelper.getScope(simplePDObject); + return AttributeHelper.getScope(simpleCOSObject); } public static String getDefaultScope(int rowNumber, int columnNumber) { diff --git a/validation-model/src/main/java/org/verapdf/gf/model/impl/pd/gfse/GFSETableCell.java b/validation-model/src/main/java/org/verapdf/gf/model/impl/pd/gfse/GFSETableCell.java index 54d5ef6a7..a4a82e331 100644 --- a/validation-model/src/main/java/org/verapdf/gf/model/impl/pd/gfse/GFSETableCell.java +++ b/validation-model/src/main/java/org/verapdf/gf/model/impl/pd/gfse/GFSETableCell.java @@ -38,12 +38,12 @@ public GFSETableCell(PDStructElem structElemDictionary, String standardType, Str @Override public Long getColSpan() { - return AttributeHelper.getColSpan(simplePDObject); + return AttributeHelper.getColSpan(simpleCOSObject); } @Override public Long getRowSpan() { - return AttributeHelper.getRowSpan(simplePDObject); + return AttributeHelper.getRowSpan(simpleCOSObject); } public int getRowNumber() { diff --git a/wcag-validation/src/main/java/org/verapdf/gf/model/impl/sa/GFSAAttributesDictionary.java b/wcag-validation/src/main/java/org/verapdf/gf/model/impl/sa/GFSAAttributesDictionary.java index 8e48f8ecb..6a8448dda 100644 --- a/wcag-validation/src/main/java/org/verapdf/gf/model/impl/sa/GFSAAttributesDictionary.java +++ b/wcag-validation/src/main/java/org/verapdf/gf/model/impl/sa/GFSAAttributesDictionary.java @@ -38,11 +38,11 @@ public GFSAAttributesDictionary(PDStructElem pdStructElem) { @Override public long getColSpan() { - return AttributeHelper.getColSpan(pdStructElem); + return AttributeHelper.getColSpan(pdStructElem.getObject()); } @Override public long getRowSpan() { - return AttributeHelper.getRowSpan(pdStructElem); + return AttributeHelper.getRowSpan(pdStructElem.getObject()); } } diff --git a/wcag-validation/src/main/java/org/verapdf/gf/model/impl/sa/structelems/GFSAFigure.java b/wcag-validation/src/main/java/org/verapdf/gf/model/impl/sa/structelems/GFSAFigure.java index da4337eee..ec505af6b 100644 --- a/wcag-validation/src/main/java/org/verapdf/gf/model/impl/sa/structelems/GFSAFigure.java +++ b/wcag-validation/src/main/java/org/verapdf/gf/model/impl/sa/structelems/GFSAFigure.java @@ -36,6 +36,6 @@ public GFSAFigure(PDStructElem structElemDictionary, String parentsStandardTypes @Override public Boolean gethasBBox() { - return AttributeHelper.getBBox(this.structElemDictionary) != null; + return AttributeHelper.getBBox(this.structElemDictionary.getObject()) != null; } }