public int createTask ( TaskCreate task , boolean silent , boolean hook ) { TaskCreateResponse response = getResourceFactory ( ) . getApiResource ( "/task/" ) . queryParam ( "silent" , silent ? "1" : "0" ) . queryParam ( "hook" , hook ? "1" : "0" ) . entity ( task , MediaType . APPLICATION_JSON_TYPE ) . post ( TaskCreateResponse . class ) ; return response . getId ( ) ; }
Creates a new task with no reference to other objects .