OpenSplice Java 5 DCPS  v6.x
OpenSplice Java 5 OpenSplice Data Distribution Service Data-Centric Publish-Subscribe API
Publisher.java
Go to the documentation of this file.
1 /* Copyright 2010, Object Management Group, Inc.
2  * Copyright 2010, PrismTech, Inc.
3  * Copyright 2010, Real-Time Innovations, Inc.
4  * All rights reserved.
5  *
6  * Licensed under the Apache License, Version 2.0 (the "License");
7  * you may not use this file except in compliance with the License.
8  * You may obtain a copy of the License at
9  *
10  * http://www.apache.org/licenses/LICENSE-2.0
11  *
12  * Unless required by applicable law or agreed to in writing, software
13  * distributed under the License is distributed on an "AS IS" BASIS,
14  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15  * See the License for the specific language governing permissions and
16  * limitations under the License.
17  */
18 
19 package org.omg.dds.pub;
20 
21 import java.util.Collection;
22 import java.util.concurrent.TimeUnit;
23 import java.util.concurrent.TimeoutException;
24 
25 import org.omg.dds.core.DomainEntity;
26 import org.omg.dds.core.Duration;
28 import org.omg.dds.core.status.Status;
30 import org.omg.dds.topic.Topic;
31 import org.omg.dds.topic.TopicQos;
32 
71 public interface Publisher
72 extends DomainEntity<PublisherListener, PublisherQos>
73 {
74  // --- Create (any) DataWriter: ------------------------------------------
75 
110  public <TYPE> DataWriter<TYPE> createDataWriter(
111  Topic<TYPE> topic);
112 
187  public <TYPE> DataWriter<TYPE> createDataWriter(
188  Topic<TYPE> topic,
189  DataWriterQos qos,
190  DataWriterListener<TYPE> listener,
191  Collection<Class<? extends Status>> statuses);
192 
257  public <TYPE> DataWriter<TYPE> createDataWriter(
258  Topic<TYPE> topic,
259  DataWriterQos qos,
260  DataWriterListener<TYPE> listener,
261  Class<? extends Status>... statuses);
262 
304  public <TYPE> DataWriter<TYPE> createDataWriter(
305  Topic<TYPE> topic,
306  DataWriterQos qos);
307 
308  // --- Lookup operations: ------------------------------------------------
309 
327  public <TYPE> DataWriter<TYPE> lookupDataWriter(String topicName);
328 
346  public <TYPE> DataWriter<TYPE> lookupDataWriter(Topic<TYPE> topic);
347 
348  // --- Other operations: -------------------------------------------------
349 
359  public void closeContainedEntities();
360 
386  public void suspendPublications();
387 
407  public void resumePublications();
408 
450  public void beginCoherentChanges();
451 
465  public void endCoherentChanges();
466 
496  public void waitForAcknowledgments(Duration maxWait)
497  throws TimeoutException;
498 
527  public void waitForAcknowledgments(long maxWait, TimeUnit unit)
528  throws TimeoutException;
529 
552 
571  public void setDefaultDataWriterQos(DataWriterQos qos);
572 
606 
607 
608  // --- From Entity: ------------------------------------------------------
609  @Override
611 
612  @Override
613  public DomainParticipant getParent();
614 }
The DomainParticipant object plays several roles:
StatusCondition< Publisher > getStatusCondition()
A StatusCondition object is an immutable object that specifies Condition that is associated with each...
void waitForAcknowledgments(Duration maxWait)
This operation blocks the calling thread until either all data written by the reliable org...
void endCoherentChanges()
This operation terminates the &#39;coherent set&#39; initiated by the matching call to beginCoherentChanges()...
void closeContainedEntities()
This operation closes all the entities that were created by means of the "create" operations on the P...
public< TYPE > DataWriter< TYPE > lookupDataWriter(String topicName)
This operation retrieves a previously created org.omg.dds.pub.DataWriter belonging to the Publisher t...
DomainParticipant getParent()
DomainEntity is the abstract base class for all DCPS entities, except for the org.omg.dds.domain.DomainParticipant.
DataWriter allows the application to set the value of the data to be published under a given org...
Definition: DataWriter.java:86
void suspendPublications()
This operation indicates to the Service that the application is about to make multiple modifications ...
void setDefaultDataWriterQos(DataWriterQos qos)
This operation sets a default value of the DataWriter QoS policies, which will be used for newly crea...
Since a org.omg.dds.pub.DataWriter is a kind of org.omg.dds.core.Entity, it has the ability to have a...
void resumePublications()
This operation indicates to the Service that the application has completed the multiple changes initi...
DataWriterQos copyFromTopicQos(DataWriterQos dwQos, TopicQos tQos)
This operation copies the policies in the org.omg.dds.topic.Topic QoS to the corresponding policies i...
A Publisher is the object responsible for the actual dissemination of publications.
Definition: Publisher.java:71
A span of elapsed time expressed with nanosecond precision.
Definition: Duration.java:35
Topic is the most basic description of the data to be published and subscribed.
Definition: Topic.java:55
DataWriterQos getDefaultDataWriterQos()
This operation retrieves the default value of the DataWriter QoS, that is, the QoS policies which wil...
void beginCoherentChanges()
This operation requests that the application will begin a &#39;coherent set&#39; of modifications using org...
Status is the abstract root class for all communication status objects.
Definition: Status.java:41
public< TYPE > DataWriter< TYPE > createDataWriter(Topic< TYPE > topic)
This operation creates a DataWriter.