aboutsummaryrefslogtreecommitdiff
path: root/classes/IsisConnector.php
diff options
context:
space:
mode:
authorSilvio <silvio@devlet.com.br>2010-07-20 16:19:06 -0300
committerSilvio <silvio@devlet.com.br>2010-07-20 16:19:06 -0300
commitcf0c2004051d538b0bd6105567b3af4a87913e52 (patch)
treeb89ce752a000ecca541693ce989beddace7d34df /classes/IsisConnector.php
parentd8d0a53b90de6b3184a01f1f075cdddf45e3caaa (diff)
downloadcinisis-cf0c2004051d538b0bd6105567b3af4a87913e52.tar.gz
cinisis-cf0c2004051d538b0bd6105567b3af4a87913e52.tar.bz2
New method explodeItem() at IsisConnector
Diffstat (limited to 'classes/IsisConnector.php')
-rw-r--r--classes/IsisConnector.php21
1 files changed, 20 insertions, 1 deletions
diff --git a/classes/IsisConnector.php b/classes/IsisConnector.php
index c82d479..ff057c6 100644
--- a/classes/IsisConnector.php
+++ b/classes/IsisConnector.php
@@ -196,7 +196,7 @@ class IsisConnector {
* @return
* Item data.
*/
- public function getItem($field, $item, $row) {
+ public function getItem($field, $item, $row = 0) {
$main_field = $this->getMainItemName($field);
if ($field == $main_field) {
@@ -518,6 +518,25 @@ class IsisConnector {
}
/**
+ * Explode brackets for a given item, avoiding null entries.
+ *
+ * @param $field
+ * Field data.
+ *
+ * @param $item
+ * Item.
+ *
+ * @param $row
+ * Row number.
+ *
+ * @return
+ * Exploded item data.
+ */
+ public function explodeItem($field, $item, $row) {
+ return array_filter($this->explodeValue($this->getItem($field, $item, $row)));
+ }
+
+ /**
* Filter brackets for a given subfield.
*
* @param $field