Sample code for 30+ languages & platforms
Go

Transition from MailMan.LastJsonData to MailMan.GetLastJsonData

Provides instructions for replacing deprecated LastJsonData method calls with GetLastJsonData.

Chilkat Go Downloads

Go
    mailman := chilkat.NewMailMan()

    // ...
    // ...

    // ------------------------------------------------------------------------
    // The LastJsonData method is deprecated:

    jsonObj := mailman.LastJsonData()
    if mailman.LastMethodSuccess() == false {
        fmt.Println(mailman.LastErrorText())
        mailman.DisposeMailMan()
        return
    }

    // ...
    // ...

    jsonObj.DisposeJsonObject()

    // ------------------------------------------------------------------------
    // Do the equivalent using GetLastJsonData.
    // Your application creates a new, empty JsonObject object which is passed 
    // in the last argument.

    jsonOut := chilkat.NewJsonObject()
    mailman.GetLastJsonData(jsonOut)

    mailman.DisposeMailMan()
    jsonOut.DisposeJsonObject()