]> git.mxchange.org Git - hub.git/blobdiff - application/hub/main/class_BaseHubSystem.php
Used exit() instead of die()
[hub.git] / application / hub / main / class_BaseHubSystem.php
index e72cbd3ef39a8524df1729eda5632504e4ef3630..03579227987b32f3114470a5900b96f0ebb9471d 100644 (file)
@@ -593,6 +593,20 @@ class BaseHubSystem extends BaseFrameworkSystem {
                // Return result
                return $stateName;
        }
+
+       /**
+        * Checks whether start/end marker are set
+        *
+        * @param       $data   Data to be checked
+        * @return      $isset  Whether start/end marker are set
+        */
+       public final function ifStartEndMarkerSet ($data) {
+               // Determine it
+               $isset = ((substr($data, 0, strlen(BaseRawDataHandler::STREAM_START_MARKER)) == BaseRawDataHandler::STREAM_START_MARKER) && (substr($data, -1 * strlen(BaseRawDataHandler::STREAM_END_MARKER), strlen(BaseRawDataHandler::STREAM_END_MARKER)) == BaseRawDataHandler::STREAM_END_MARKER));
+
+               // ... and return it
+               return $isset;
+       }
 }
 
 // [EOF]