No longer throwing deprecated exceptions
[shipsimu.git] / application / ship-simu / main / companies / class_ShippingCompany.php
index 972e6e4dbfec7798c10e34ff34df249639b914ba..9ffb6048c5c51063a8e026315cf3c102d1caf456 100644 (file)
@@ -403,7 +403,7 @@ class ShippingCompany extends BaseSimulator implements Customer, ContractPartner
                                throw new NullPointerException($this, self::EXCEPTION_IS_NULL_POINTER);
                        } elseif (!is_object($shipyard)) {
                                // Not an object! ;-(
-                               throw new NoObjectException($shipyard, self::EXCEPTION_IS_NO_OBJECT);
+                               throw new InvalidObjectException($shipyard, self::EXCEPTION_IS_NO_OBJECT);
                        } elseif ($shipyard->isClass("Shipyard") === false) {
                                // Nope, so throw exception
                                throw new ClassMismatchException(array($shipyard->__toString(), "Shipyard"), self::EXCEPTION_CLASSES_NOT_MATCHING);
@@ -491,7 +491,7 @@ class ShippingCompany extends BaseSimulator implements Customer, ContractPartner
                                throw new NullPointerException($this, self::EXCEPTION_IS_NULL_POINTER);
                        } elseif (!is_object($shipyard)) {
                                // Not an object! ;-(
-                               throw new NoObjectException($shipyard, self::EXCEPTION_IS_NO_OBJECT);
+                               throw new InvalidObjectException($shipyard, self::EXCEPTION_IS_NO_OBJECT);
                        } elseif ($shipyard->isClass("Shipyard") === false) {
                                // Class is not a shipyard
                                throw new ClassMismatchException(array($shipyard->__toString(), "Shipyard"), self::EXCEPTION_CLASSES_NOT_MATCHING);
@@ -513,7 +513,7 @@ class ShippingCompany extends BaseSimulator implements Customer, ContractPartner
                        throw new NullPointerException($this, self::EXCEPTION_IS_NULL_POINTER);
                } elseif (!is_object($shipInstance)) {
                        // Not an object! ;-(
-                       throw new NoObjectException($shipInstance, self::EXCEPTION_IS_NO_OBJECT);
+                       throw new InvalidObjectException($shipInstance, self::EXCEPTION_IS_NO_OBJECT);
                }
 
                // Get it's real class name
@@ -550,7 +550,7 @@ class ShippingCompany extends BaseSimulator implements Customer, ContractPartner
                                throw new NullPointerException($this, self::EXCEPTION_IS_NULL_POINTER);
                        } elseif (!is_object($shipyard)) {
                                // Not an object! ;-(
-                               throw new NoObjectException($shipyard, self::EXCEPTION_IS_NO_OBJECT);
+                               throw new InvalidObjectException($shipyard, self::EXCEPTION_IS_NO_OBJECT);
                        } elseif ($shipyard->isClass("Shipyard") === false) {
                                // Class is not a shipyard
                                throw new ClassMismatchException(array($shipyard->__toString(), "Shipyard"), self::EXCEPTION_CLASSES_NOT_MATCHING);
@@ -651,7 +651,7 @@ class ShippingCompany extends BaseSimulator implements Customer, ContractPartner
                        throw new NullPointerException($this, self::EXCEPTION_IS_NULL_POINTER);
                } elseif (!is_object($contractInstance)) {
                        // Not an object! ;-(
-                       throw new NoObjectException($contractInstance, self::EXCEPTION_IS_NO_OBJECT);
+                       throw new InvalidObjectException($contractInstance, self::EXCEPTION_IS_NO_OBJECT);
                } elseif ($contractInstance->isClass("WorksContract") === false) {
                        // Is not a merchant
                        throw new ClassMismatchException(array($contractInstance->__toString(), "WorksContract"), self::EXCEPTION_CLASSES_NOT_MATCHING);