Java Code Examples for com.google.zxing.pdf417.PDF417Common#toIntArray()
The following examples show how to use
com.google.zxing.pdf417.PDF417Common#toIntArray() .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: BarcodeValue.java From ZXing-Orient with Apache License 2.0 | 5 votes |
/** * Determines the maximum occurrence of a set value and returns all values which were set with this occurrence. * @return an array of int, containing the values with the highest occurrence, or null, if no value was set */ int[] getValue() { int maxConfidence = -1; Collection<Integer> result = new ArrayList<>(); for (Entry<Integer,Integer> entry : values.entrySet()) { if (entry.getValue() > maxConfidence) { maxConfidence = entry.getValue(); result.clear(); result.add(entry.getKey()); } else if (entry.getValue() == maxConfidence) { result.add(entry.getKey()); } } return PDF417Common.toIntArray(result); }
Example 2
Source File: BarcodeValue.java From analyzer-of-android-for-Apache-Weex with Apache License 2.0 | 5 votes |
/** * Determines the maximum occurrence of a set value and returns all values which were set with this occurrence. * @return an array of int, containing the values with the highest occurrence, or null, if no value was set */ int[] getValue() { int maxConfidence = -1; Collection<Integer> result = new ArrayList<>(); for (Entry<Integer,Integer> entry : values.entrySet()) { if (entry.getValue() > maxConfidence) { maxConfidence = entry.getValue(); result.clear(); result.add(entry.getKey()); } else if (entry.getValue() == maxConfidence) { result.add(entry.getKey()); } } return PDF417Common.toIntArray(result); }
Example 3
Source File: BarcodeValue.java From weex with Apache License 2.0 | 5 votes |
/** * Determines the maximum occurrence of a set value and returns all values which were set with this occurrence. * @return an array of int, containing the values with the highest occurrence, or null, if no value was set */ int[] getValue() { int maxConfidence = -1; Collection<Integer> result = new ArrayList<>(); for (Entry<Integer,Integer> entry : values.entrySet()) { if (entry.getValue() > maxConfidence) { maxConfidence = entry.getValue(); result.clear(); result.add(entry.getKey()); } else if (entry.getValue() == maxConfidence) { result.add(entry.getKey()); } } return PDF417Common.toIntArray(result); }
Example 4
Source File: BarcodeValue.java From barcodescanner-lib-aar with MIT License | 5 votes |
/** * Determines the maximum occurrence of a set value and returns all values which were set with this occurrence. * @return an array of int, containing the values with the highest occurrence, or null, if no value was set */ int[] getValue() { int maxConfidence = -1; Collection<Integer> result = new ArrayList<>(); for (Entry<Integer,Integer> entry : values.entrySet()) { if (entry.getValue() > maxConfidence) { maxConfidence = entry.getValue(); result.clear(); result.add(entry.getKey()); } else if (entry.getValue() == maxConfidence) { result.add(entry.getKey()); } } return PDF417Common.toIntArray(result); }