本文整理汇总了C++中DataInputStream::available方法的典型用法代码示例。如果您正苦于以下问题:C++ DataInputStream::available方法的具体用法?C++ DataInputStream::available怎么用?C++ DataInputStream::available使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类DataInputStream
的用法示例。
在下文中一共展示了DataInputStream::available方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1:
int codeVersionTable1_3::read(DataInputStream& istream ) { // throws IOException
int retVal = 0;
// read header
retVal += header->read(istream);
// read length
{
length=(istream.readUI8());
retVal+=1;
}
// read configurationCountChange
{
configurationCountChange=(istream.readUI8());
retVal+=1;
}
// read statusField
{
statusField=(istream.readUI8());
retVal+=1;
}
// read pgmmsg
for (; istream.available() > 0 ; ) {
org_himalay_ccif_codeVersionTableMsg__PTR_TYPE temp;
org_himalay_ccif_codeVersionTableMsg__NEW( temp);
retVal += temp->read(istream);
pgmmsg.add(temp);
}
// read bf1
bf1= istream.readUI8();
retVal += 1;
// read statusfldInstance
if (getDownload_type()==0x00) {
org_himalay_ccif_codeVersionTable1_3_statusfld__NEW( statusfldInstance);
statusfldInstance->parent=this;
retVal += statusfldInstance->read(istream);
}
// read statusfld2Instance
if (getDownload_type()==0x01) {
org_himalay_ccif_codeVersionTable1_3_statusfld2__NEW( statusfld2Instance);
statusfld2Instance->parent=this;
retVal += statusfld2Instance->read(istream);
}
// read statusfld3Instance
if (getDownload_type()==0x02) {
org_himalay_ccif_codeVersionTable1_3_statusfld3__NEW( statusfld3Instance);
statusfld3Instance->parent=this;
retVal += statusfld3Instance->read(istream);
}
// read codeFileByte
{
retVal+=codeFileByte->read(istream);
}
// read codeVeriFicationCertiFication
retVal += codeVeriFicationCertiFication->read(istream);
return retVal;
}
示例2: read
int SoftwareVerReportS_Mode::read(DataInputStream& istream ) { // throws IOException
int retVal = 0;
// read applicationsInReport
for (; istream.available() > 0 ; ) {
org_himalay_ccif_softwareVerSMsg__PTR_TYPE temp;
org_himalay_ccif_softwareVerSMsg__NEW( temp);
retVal += temp->read(istream);
applicationsInReport.add(temp);
}
return retVal;
}