WC_REST_CRUD_Controller::get_object() protected WC 1.0
Get object.
{} It's a method of the class: WC_REST_CRUD_Controller{}
No Hooks.
Return
Object. WC_Data object or WP_Error object.
Usage
// protected - for code of main (parent) or child class $result = $this->get_object( $id );
- $id(int) (required)
- Object ID.
Code of WC_REST_CRUD_Controller::get_object() WC REST CRUD Controller::get object WC 5.0.0
protected function get_object( $id ) {
// translators: %s: Class method name.
return new WP_Error( 'invalid-method', sprintf( __( "Method '%s' not implemented. Must be overridden in subclass.", 'woocommerce' ), __METHOD__ ), array( 'status' => 405 ) );
}