|
| 1 | +--- |
| 2 | +layout: default-layout |
| 3 | +title: CandidateQuadEdgesUnit Class |
| 4 | +description: This page shows CandidateQuadEdgesUnit class definition of Dynamsoft Document Normalizer SDK Java Edition. |
| 5 | +keywords: getCount, getCandidateQuadEdge, CandidateQuadEdgesUnit, api reference |
| 6 | +--- |
| 7 | + |
| 8 | +# CandidateQuadEdgesUnit Class |
| 9 | + |
| 10 | +The `CandidateQuadEdgesUnit` class represents an intermediate result unit whose type is candidate quad edges. |
| 11 | + |
| 12 | +## Definition |
| 13 | + |
| 14 | +*Package:* com.dynamsoft.ddn.intermediate_results |
| 15 | + |
| 16 | +```java |
| 17 | +public class CandidateQuadEdgesUnit extends IntermediateResultUnit |
| 18 | +``` |
| 19 | + |
| 20 | +*Inheritance:* [IntermediateResultUnit]({{ site.dcvb_java_api }}core/intermediate-results/intermediate-result-unit.html) -> CandidateQuadEdgesUnit |
| 21 | + |
| 22 | +## Methods |
| 23 | + |
| 24 | +| Method | Description | |
| 25 | +|--------|-------------| |
| 26 | +| [`getCount`](#getcount) | Gets the count of `Edge` objects in current object.| |
| 27 | +| [`getCandidateQuadEdge`](#getcandidatequadedge) | Gets an `Edge` object from current object by specifying a index. | |
| 28 | +| [`getCandidateQuadEdges`](#getcandidatequadedges) | Gets all `Edge` objects in current object. | |
| 29 | +| [`removeAllCandidateQuadEdges`](#removeallcandidatequadedges) | Removes all the candidate quad edges in current object. | |
| 30 | +| [`removeCandidateQuadEdge`](#removecandidatequadedge) | Removes a candidate quad edge from current object by specifying an index. | |
| 31 | +| [`addCandidateQuadEdge`](#addcandidatequadedge) | Adds a candidate quad edge to current object. | |
| 32 | +| [`setCandidateQuadEdge`](#setcandidatequadedge) | Sets the candidate quad edge at the specified index. | |
| 33 | + |
| 34 | +### getCount |
| 35 | + |
| 36 | +Gets the count of `Edge` objects in current object. |
| 37 | + |
| 38 | +```java |
| 39 | +public int getCount() |
| 40 | +``` |
| 41 | + |
| 42 | +**Return Value** |
| 43 | + |
| 44 | +The count of `Edge` objects in current object. |
| 45 | + |
| 46 | +### getCandidateQuadEdge |
| 47 | + |
| 48 | +Gets an `Edge` object from current object by specifying a index. |
| 49 | + |
| 50 | +```java |
| 51 | +public Edge getCandidateQuadEdge(int index) throws DocumentNormalizerException |
| 52 | +``` |
| 53 | + |
| 54 | +**Parameters** |
| 55 | + |
| 56 | +`index` The index of the `Edge` object. |
| 57 | + |
| 58 | +**Return Value** |
| 59 | + |
| 60 | +Returns the `Edge` object got by the specific index. |
| 61 | + |
| 62 | +**Exceptions** |
| 63 | + |
| 64 | +[`DocumentNormalizerException`](document-normalizer-exception.html) |
| 65 | + |
| 66 | +**See Also** |
| 67 | + |
| 68 | +[Edge]({{ site.dcvb_java_api }}core/basic-classes/edge.html) |
| 69 | + |
| 70 | +### getCandidateQuadEdges |
| 71 | + |
| 72 | +Gets all `Edge` objects in current object. |
| 73 | + |
| 74 | +```java |
| 75 | +public Edge[] getCandidateQuadEdges() |
| 76 | +``` |
| 77 | + |
| 78 | +**Return Value** |
| 79 | + |
| 80 | +Returns an array of `Edge` objects. |
| 81 | + |
| 82 | +**See Also** |
| 83 | + |
| 84 | +[Edge]({{ site.dcvb_java_api }}core/basic-classes/edge.html) |
| 85 | + |
| 86 | +### removeAllCandidateQuadEdges |
| 87 | + |
| 88 | +Removes all the candidate quad edges in current object. |
| 89 | + |
| 90 | +```java |
| 91 | +public void removeAllCandidateQuadEdges() |
| 92 | +``` |
| 93 | + |
| 94 | +### removeCandidateQuadEdge |
| 95 | + |
| 96 | +Removes a candidate quad edge from current object by specifying an index. |
| 97 | + |
| 98 | +```java |
| 99 | +public void removeCandidateQuadEdge(int index) throws DocumentNormalizerException |
| 100 | +``` |
| 101 | + |
| 102 | +**Parameters** |
| 103 | + |
| 104 | +`index` The index of the candidate quad edge to be removed. |
| 105 | + |
| 106 | +**Exceptions** |
| 107 | + |
| 108 | +[`DocumentNormalizerException`](document-normalizer-exception.html) |
| 109 | + |
| 110 | +### addCandidateQuadEdge |
| 111 | + |
| 112 | +Adds a candidate quad edge to current object. |
| 113 | + |
| 114 | +```java |
| 115 | +public void addCandidateQuadEdge(Edge edge) throws DocumentNormalizerException |
| 116 | +public void addCandidateQuadEdge(Edge edge, double[] matrixToOriginalImage) throws DocumentNormalizerException |
| 117 | +``` |
| 118 | + |
| 119 | +**Parameters** |
| 120 | + |
| 121 | +`edge` The candidate quad edge to be added. |
| 122 | + |
| 123 | +`matrixToOriginalImage` The matrix to the original image. |
| 124 | + |
| 125 | +**Exceptions** |
| 126 | + |
| 127 | +[`DocumentNormalizerException`](document-normalizer-exception.html) |
| 128 | + |
| 129 | +**See Also** |
| 130 | + |
| 131 | +[Edge]({{ site.dcvb_java_api }}core/basic-classes/edge.html) |
| 132 | + |
| 133 | +### setCandidateQuadEdge |
| 134 | + |
| 135 | +Sets the candidate quad edge at the specified index. |
| 136 | + |
| 137 | +```java |
| 138 | +public void setCandidateQuadEdge(int index, Edge edge) throws DocumentNormalizerException |
| 139 | +public void setCandidateQuadEdge(int index, Edge edge, double[] matrixToOriginalImage) throws DocumentNormalizerException |
| 140 | +``` |
| 141 | + |
| 142 | +**Parameters** |
| 143 | + |
| 144 | +`index` The index of the candidate quad edge to be set. |
| 145 | + |
| 146 | +`edge` The candidate quad edge to be added. |
| 147 | + |
| 148 | +`matrixToOriginalImage` The matrix to the original image. |
| 149 | + |
| 150 | +**Exceptions** |
| 151 | + |
| 152 | +[`DocumentNormalizerException`](document-normalizer-exception.html) |
| 153 | + |
| 154 | +**See Also** |
| 155 | + |
| 156 | +[Edge]({{ site.dcvb_java_api }}core/basic-classes/edge.html) |
0 commit comments