本文整理了Java中com.amazonaws.services.simpleemail.model.Body.setText()
方法的一些代码示例,展示了Body.setText()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Body.setText()
方法的具体详情如下:
包路径:com.amazonaws.services.simpleemail.model.Body
类名称:Body
方法名:setText
[英]The content of the message, in text format. Use this for text-based email clients, or clients on high-latency networks (such as mobile devices).
[中]以文本格式显示消息的内容。用于基于文本的电子邮件客户端,或高延迟网络(如移动设备)上的客户端。
代码示例来源:origin: aws/aws-sdk-java
/**
* Constructs a new Body object. Callers should use the setter or fluent setter (with...) methods to initialize any
* additional object members.
*
* @param text
* The content of the message, in text format. Use this for text-based email clients, or clients on
* high-latency networks (such as mobile devices).
*/
public Body(Content text) {
setText(text);
}
代码示例来源:origin: aws/aws-sdk-java
/**
* <p>
* The content of the message, in text format. Use this for text-based email clients, or clients on high-latency
* networks (such as mobile devices).
* </p>
*
* @param text
* The content of the message, in text format. Use this for text-based email clients, or clients on
* high-latency networks (such as mobile devices).
* @return Returns a reference to this object so that method calls can be chained together.
*/
public Body withText(Content text) {
setText(text);
return this;
}
代码示例来源:origin: aws/aws-sdk-java
public Body unmarshall(StaxUnmarshallerContext context) throws Exception {
Body body = new Body();
int originalDepth = context.getCurrentDepth();
int targetDepth = originalDepth + 1;
if (context.isStartOfDocument())
targetDepth += 1;
while (true) {
XMLEvent xmlEvent = context.nextEvent();
if (xmlEvent.isEndDocument())
return body;
if (xmlEvent.isAttribute() || xmlEvent.isStartElement()) {
if (context.testExpression("Text", targetDepth)) {
body.setText(ContentStaxUnmarshaller.getInstance().unmarshall(context));
continue;
}
if (context.testExpression("Html", targetDepth)) {
body.setHtml(ContentStaxUnmarshaller.getInstance().unmarshall(context));
continue;
}
} else if (xmlEvent.isEndElement()) {
if (context.getCurrentDepth() < originalDepth) {
return body;
}
}
}
}
代码示例来源:origin: aws-amplify/aws-sdk-android
/**
* Constructs a new Body object. Callers should use the setter or fluent
* setter (with...) methods to initialize any additional object members.
*
* @param text <p>
* The content of the message, in text format. Use this for
* text-based email clients, or clients on high-latency networks
* (such as mobile devices).
* </p>
*/
public Body(Content text) {
setText(text);
}
代码示例来源:origin: com.amazonaws/aws-java-sdk-ses
/**
* Constructs a new Body object. Callers should use the setter or fluent setter (with...) methods to initialize any
* additional object members.
*
* @param text
* The content of the message, in text format. Use this for text-based email clients, or clients on
* high-latency networks (such as mobile devices).
*/
public Body(Content text) {
setText(text);
}
代码示例来源:origin: com.amazonaws/aws-java-sdk-ses
/**
* <p>
* The content of the message, in text format. Use this for text-based email clients, or clients on high-latency
* networks (such as mobile devices).
* </p>
*
* @param text
* The content of the message, in text format. Use this for text-based email clients, or clients on
* high-latency networks (such as mobile devices).
* @return Returns a reference to this object so that method calls can be chained together.
*/
public Body withText(Content text) {
setText(text);
return this;
}
代码示例来源:origin: aws-amplify/aws-sdk-android
public Body unmarshall(StaxUnmarshallerContext context) throws Exception {
Body body = new Body();
int originalDepth = context.getCurrentDepth();
int targetDepth = originalDepth + 1;
if (context.isStartOfDocument())
targetDepth += 2;
while (true) {
int xmlEvent = context.nextEvent();
if (xmlEvent == XmlPullParser.END_DOCUMENT)
break;
if (xmlEvent == XmlPullParser.START_TAG) {
if (context.testExpression("Text", targetDepth)) {
body.setText(ContentStaxUnmarshaller.getInstance().unmarshall(context));
continue;
}
if (context.testExpression("Html", targetDepth)) {
body.setHtml(ContentStaxUnmarshaller.getInstance().unmarshall(context));
continue;
}
} else if (xmlEvent == XmlPullParser.END_TAG) {
if (context.getCurrentDepth() < originalDepth) {
break;
}
}
}
return body;
}
代码示例来源:origin: com.amazonaws/aws-java-sdk-ses
public Body unmarshall(StaxUnmarshallerContext context) throws Exception {
Body body = new Body();
int originalDepth = context.getCurrentDepth();
int targetDepth = originalDepth + 1;
if (context.isStartOfDocument())
targetDepth += 1;
while (true) {
XMLEvent xmlEvent = context.nextEvent();
if (xmlEvent.isEndDocument())
return body;
if (xmlEvent.isAttribute() || xmlEvent.isStartElement()) {
if (context.testExpression("Text", targetDepth)) {
body.setText(ContentStaxUnmarshaller.getInstance().unmarshall(context));
continue;
}
if (context.testExpression("Html", targetDepth)) {
body.setHtml(ContentStaxUnmarshaller.getInstance().unmarshall(context));
continue;
}
} else if (xmlEvent.isEndElement()) {
if (context.getCurrentDepth() < originalDepth) {
return body;
}
}
}
}
内容来源于网络,如有侵权,请联系作者删除!