本文整理汇总了C#中DDS.GetRequestedDeadlineMissedStatus方法的典型用法代码示例。如果您正苦于以下问题:C# DDS.GetRequestedDeadlineMissedStatus方法的具体用法?C# DDS.GetRequestedDeadlineMissedStatus怎么用?C# DDS.GetRequestedDeadlineMissedStatus使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类DDS
的用法示例。
在下文中一共展示了DDS.GetRequestedDeadlineMissedStatus方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: RequestedDeadlineMissedValid
public static bool RequestedDeadlineMissedValid(DDS.IDataReader reader, int totalCount
, int totalCountChange)
{
bool result = false;
DDS.RequestedDeadlineMissedStatus holder = new DDS.RequestedDeadlineMissedStatus();
DDS.ReturnCode rc = reader.GetRequestedDeadlineMissedStatus(ref holder);
if (rc == DDS.ReturnCode.Ok)
{
DDS.RequestedDeadlineMissedStatus status = holder;
if (status.TotalCount == totalCount)
{
if (status.TotalCountChange == totalCountChange)
{
result = true;
}
else
{
System.Console.Error.WriteLine("requested_deadline_missed.TotalCountChange != '"
+ totalCountChange + "', but '" + status.TotalCountChange + "'.");
}
}
else
{
System.Console.Error.WriteLine("requested_deadline_missed.TotalCount != '" + totalCount
+ "', but '" + status.TotalCount + "'.");
}
}
else
{
System.Console.Error.WriteLine("get_requested_deadline_missed_status returned " +
rc);
}
return result;
}
示例2: PrintStatusses
private void PrintStatusses(DDS.IDataReader reader)
{
DDS.ReturnCode rc;
DDS.RequestedDeadlineMissedStatus rdmsHolder = new DDS.RequestedDeadlineMissedStatus();
rc = reader.GetRequestedDeadlineMissedStatus(ref rdmsHolder);
DDS.RequestedDeadlineMissedStatus rdms = rdmsHolder;
if (rc != DDS.ReturnCode.Ok)
{
System.Console.Error.WriteLine("Unable to resolve status!");
return;
}
DDS.RequestedIncompatibleQosStatus riqsHolder = new DDS.RequestedIncompatibleQosStatus();
rc = reader.GetRequestedIncompatibleQosStatus(ref riqsHolder);
DDS.RequestedIncompatibleQosStatus riqs = riqsHolder;
if (rc != DDS.ReturnCode.Ok)
{
System.Console.Error.WriteLine("Unable to resolve status!");
return;
}
DDS.SampleRejectedStatus srsHolder = new DDS.SampleRejectedStatus();
rc = reader.GetSampleRejectedStatus(ref srsHolder);
DDS.SampleRejectedStatus srs = srsHolder;
if (rc != DDS.ReturnCode.Ok)
{
System.Console.Error.WriteLine("Unable to resolve status!");
return;
}
DDS.LivelinessChangedStatus lcsHolder = new DDS.LivelinessChangedStatus();
rc = reader.GetLivelinessChangedStatus(ref lcsHolder);
DDS.LivelinessChangedStatus lcs = lcsHolder;
if (rc != DDS.ReturnCode.Ok)
{
System.Console.Error.WriteLine("Unable to resolve status!");
return;
}
DDS.SubscriptionMatchedStatus smsHolder = new DDS.SubscriptionMatchedStatus();
rc = reader.GetSubscriptionMatchedStatus(ref smsHolder);
DDS.SubscriptionMatchedStatus sms = smsHolder;
if (rc != DDS.ReturnCode.Ok)
{
System.Console.Error.WriteLine("Unable to resolve status!");
return;
}
DDS.SampleLostStatus slsHolder = new DDS.SampleLostStatus();
rc = reader.GetSampleLostStatus(ref slsHolder);
DDS.SampleLostStatus sls = slsHolder;
if (rc != DDS.ReturnCode.Ok)
{
System.Console.Error.WriteLine("Unable to resolve status!");
return;
}
System.Console.Out.WriteLine("requested_deadline_missed.TotalCount : " +
rdms.TotalCount);
System.Console.Out.WriteLine("requested_deadline_missed.TotalCountChange : " +
rdms.TotalCountChange);
System.Console.Out.WriteLine("requested_deadline_missed.LastInstanceHandle: " +
rdms.LastInstanceHandle);
System.Console.Out.WriteLine("requested_incompatible_qos.TotalCount : " +
riqs.TotalCount);
System.Console.Out.WriteLine("requested_incompatible_qos.TotalCountChange : " +
riqs.TotalCountChange);
System.Console.Out.WriteLine("requested_incompatible_qos.LastPolicyId : " +
riqs.LastPolicyId);
System.Console.Out.WriteLine("sample_rejected.TotalCount : " +
srs.TotalCount);
System.Console.Out.WriteLine("sample_rejected.TotalCountChange : " +
srs.TotalCountChange);
System.Console.Out.WriteLine("sample_rejected.LastInstanceHandle : " +
srs.LastInstanceHandle);
System.Console.Out.WriteLine("liveliness_changed.AliveCount : " +
lcs.AliveCount);
System.Console.Out.WriteLine("liveliness_changed.AliveCountChange : " +
lcs.AliveCountChange);
System.Console.Out.WriteLine("liveliness_changed.not_alive_count : " +
lcs.NotAliveCount);
System.Console.Out.WriteLine("liveliness_changed.not_alive_count_change : " +
lcs.NotAliveCountChange);
System.Console.Out.WriteLine("subscription_match.TotalCount : " +
sms.TotalCount);
System.Console.Out.WriteLine("subscription_match.TotalCountChange : " +
sms.TotalCountChange);
System.Console.Out.WriteLine("subscription_match.last_publication_handle : " +
sms.LastPublicationHandle);
System.Console.Out.WriteLine("sample_lost.TotalCount : " +
sls.TotalCount);
System.Console.Out.WriteLine("sample_lost.TotalCountChange : " +
sls.TotalCountChange + "\n");
}