protected < T > void deleteResource ( String path , Class < T > objectClass ) throws SmartsheetException { Util . throwIfNull ( path , objectClass ) ; Util . throwIfEmpty ( path ) ; HttpRequest request ; request = createHttpRequest ( smartsheet . getBaseURI ( ) . resolve ( path ) , HttpMethod . DELETE ) ; try { HttpResponse response = this . smartsheet . getHttpClient ( ) . request ( request ) ; switch ( response . getStatusCode ( ) ) { case 200 : this . smartsheet . getJsonSerializer ( ) . deserializeResult ( objectClass , response . getEntity ( ) . getContent ( ) ) ; break ; default : handleError ( response ) ; } } finally { smartsheet . getHttpClient ( ) . releaseConnection ( ) ; } }
Delete a resource from Smartsheet REST API .