// Path: src/main/java/com/mailosaur/models/SpamAnalysisResult.java
// public class SpamAnalysisResult {
//     /**
//      * Spam filter results.
//      */
//     @Key
//     private SpamFilterResults spamFilterResults;
// 
//     /**
//      * Overall Mailosaur spam score.
//      */
//     @Key
//     private Double score;
// 
//     /**
//      * Gets the Spam filter results.
//      *
//      * @return Spam filter results.
//      */
//     public SpamFilterResults spamFilterResults() {
//         return this.spamFilterResults;
//     }
//     
//     /**
//      * Gets the overall Mailosaur spam score.
//      *
//      * @return The overall Mailosaur spam score.
//      */
//     public Double score() {
//         return this.score;
//     }
// 
// }


import java.io.IOException;
import com.mailosaur.models.SpamAnalysisResult;
package com.mailosaur;



/**
 * Message analysis operations.
 */
public class Analysis {
    private MailosaurClient client;
    
    public Analysis(MailosaurClient client) {
        this.client = client;
    }

    /**
     * Perform a spam analysis of an email.
     *
     * @param messageId The identifier of the message to be analyzed.
     * @throws MailosaurException Thrown if Mailosaur responds with an error.
     * @throws IOException Unexpected exception.
     * @return The results of spam analysis performed by Mailosaur.
     */
// Path: src/main/java/com/mailosaur/models/SpamAnalysisResult.java
// public class SpamAnalysisResult {
//     /**
//      * Spam filter results.
//      */
//     @Key
//     private SpamFilterResults spamFilterResults;
// 
//     /**
//      * Overall Mailosaur spam score.
//      */
//     @Key
//     private Double score;
// 
//     /**
//      * Gets the Spam filter results.
//      *
//      * @return Spam filter results.
//      */
//     public SpamFilterResults spamFilterResults() {
//         return this.spamFilterResults;
//     }
//     
//     /**
//      * Gets the overall Mailosaur spam score.
//      *
//      * @return The overall Mailosaur spam score.
//      */
//     public Double score() {
//         return this.score;
//     }
// 
// }


// Path: src/main/java/com/mailosaur/Analysis.java
import java.io.IOException;
import com.mailosaur.models.SpamAnalysisResult;

package com.mailosaur;



/**
 * Message analysis operations.
 */
public class Analysis {
    private MailosaurClient client;
    
    public Analysis(MailosaurClient client) {
        this.client = client;
    }

    /**
     * Perform a spam analysis of an email.
     *
     * @param messageId The identifier of the message to be analyzed.
     * @throws MailosaurException Thrown if Mailosaur responds with an error.
     * @throws IOException Unexpected exception.
     * @return The results of spam analysis performed by Mailosaur.
     */
    public SpamAnalysisResult spam(String messageId) throws IOException, MailosaurException {