Java 类com.amazonaws.services.sns.model.GetTopicAttributesRequest 实例源码

项目:unitstack    文件:MockSnsTest.java   
@Test
public void testGetSetTopicAttributes_shouldAddAndRespondAttributes() {
  mockSns(new MockParameters());
  CreateTopicResult topicResult = sns.createTopic(new CreateTopicRequest().withName("attributefull-topic"));

  SetTopicAttributesResult setAttrResult = sns.setTopicAttributes(topicResult.getTopicArn(), "planet", "Omega 3");
  assertNotNull(setAttrResult);

  GetTopicAttributesResult topicAttributes = sns.getTopicAttributes(new GetTopicAttributesRequest().withTopicArn(topicResult.getTopicArn()));

  assertEquals("verify added attribute is correct", "Omega 3", topicAttributes.getAttributes().get("planet"));

  sns.deleteTopic(topicResult.getTopicArn());
}
项目:unitstack    文件:MockSnsTest.java   
@Test
public void testGetTopicAttributes_withNoRequestParams_shouldWork() {
  mockSns(new MockParameters());
  assertNotNull(sns.getTopicAttributes(new GetTopicAttributesRequest()));
}
项目:Camel    文件:AmazonSNSClientMock.java   
@Override
public GetTopicAttributesResult getTopicAttributes(GetTopicAttributesRequest getTopicAttributesRequest) throws AmazonServiceException, AmazonClientException {
    throw new UnsupportedOperationException();
}
项目:aws-sdk-java-resources    文件:TopicImpl.java   
@Override
public boolean load(GetTopicAttributesRequest request) {
    return load(request, null);
}
项目:aws-sdk-java-resources    文件:TopicImpl.java   
@Override
public boolean load(GetTopicAttributesRequest request,
        ResultCapture<GetTopicAttributesResult> extractor) {

    return resource.load(request, extractor);
}
项目:aws-sdk-java-resources    文件:Topic.java   
/**
 * Makes a call to the service to load this resource's attributes if they
 * are not loaded yet.
 * The following request parameters will be populated from the data of this
 * <code>Topic</code> resource, and any conflicting parameter value set in
 * the request will be overridden:
 * <ul>
 *   <li>
 *     <b><code>TopicArn</code></b>
 *         - mapped from the <code>Arn</code> identifier.
 *   </li>
 * </ul>
 *
 * <p>
 *
 * @return Returns {@code true} if the resource is not yet loaded when this
 *         method was invoked, which indicates that a service call has been
 *         made to retrieve the attributes.
 * @see GetTopicAttributesRequest
 */
boolean load(GetTopicAttributesRequest request);
项目:aws-sdk-java-resources    文件:Topic.java   
/**
 * Makes a call to the service to load this resource's attributes if they
 * are not loaded yet, and use a ResultCapture to retrieve the low-level
 * client response
 * The following request parameters will be populated from the data of this
 * <code>Topic</code> resource, and any conflicting parameter value set in
 * the request will be overridden:
 * <ul>
 *   <li>
 *     <b><code>TopicArn</code></b>
 *         - mapped from the <code>Arn</code> identifier.
 *   </li>
 * </ul>
 *
 * <p>
 *
 * @return Returns {@code true} if the resource is not yet loaded when this
 *         method was invoked, which indicates that a service call has been
 *         made to retrieve the attributes.
 * @see GetTopicAttributesRequest
 */
boolean load(GetTopicAttributesRequest request,
        ResultCapture<GetTopicAttributesResult> extractor);