public final class MIMEStructureParser
extends java.lang.Object
Modifier and Type | Method and Description |
---|---|
static void |
main(java.lang.String[] args) |
static MailMessage |
parseStructure(org.json.JSONObject jsonStructure)
Parses specified JSON mail structure to a
MailMessage instance. |
static ComposedMailMessage |
parseStructure(org.json.JSONObject jsonStructure,
com.openexchange.tools.session.ServerSession session)
Parses specified JSON mail structure to a transportable
ComposedMailMessage instance. |
static ComposedMailMessage |
parseStructure(org.json.JSONObject jsonStructure,
com.openexchange.session.Session session)
Parses specified JSON mail structure to a transportable
ComposedMailMessage instance. |
static byte[] |
parseStructure2MIME(org.json.JSONObject jsonStructure)
Parses specified JSON mail structure to corresponding RFC822 bytes.
|
public static void main(java.lang.String[] args)
public static byte[] parseStructure2MIME(org.json.JSONObject jsonStructure) throws com.openexchange.exception.OXException
jsonStructure
- The JSON mail structurecom.openexchange.exception.OXException
- If parsing failspublic static MailMessage parseStructure(org.json.JSONObject jsonStructure) throws com.openexchange.exception.OXException
MailMessage
instance.jsonStructure
- The JSON mail structureMailMessage
instancecom.openexchange.exception.OXException
- If parsing failspublic static ComposedMailMessage parseStructure(org.json.JSONObject jsonStructure, com.openexchange.session.Session session) throws com.openexchange.exception.OXException
ComposedMailMessage
instance.jsonStructure
- The JSON mail structuresession
- The sessionComposedMailMessage
instancecom.openexchange.exception.OXException
- If parsing failspublic static ComposedMailMessage parseStructure(org.json.JSONObject jsonStructure, com.openexchange.tools.session.ServerSession session) throws com.openexchange.exception.OXException
ComposedMailMessage
instance.jsonStructure
- The JSON mail structuresession
- The sessionComposedMailMessage
instancecom.openexchange.exception.OXException
- If parsing fails