001    package org.deepamehta.plugins.twitter;
002    
003    import javax.ws.rs.core.Response.Status;
004    
005    /**
006     * A very basic client for researching with the public Twitter Search API v1.1 and DeepaMehta 4.1.2
007     *
008     * @author Malte Reißig (<malte@mikromedia.de>)
009     * @website https://github.com/mukil/twitter-research
010     * @version 1.2
011     *
012     */
013    
014    public class TwitterAPIException extends Throwable {
015    
016        private Status status;
017        private String message;
018    
019        public TwitterAPIException (String message, Status status) {
020            this.status = status;
021            this.message = message;
022        }
023    
024        public TwitterAPIException (String message) {
025            this.status = Status.INTERNAL_SERVER_ERROR;
026            this.message = message;
027        }
028    
029        public Status getStatus() {
030            return this.status;
031        }
032    
033        public String getMessage() {
034            return this.message;
035        }
036    
037    }