本文整理匯總了C++中AutoPtr函數的典型用法代碼示例。如果您正苦於以下問題:C++ AutoPtr函數的具體用法?C++ AutoPtr怎麽用?C++ AutoPtr使用的例子?那麽, 這裏精選的函數代碼示例或許可以為您提供幫助。
在下文中一共展示了AutoPtr函數的5個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的C++代碼示例。
示例1: AutoPtr
LangAltValue::AutoPtr LangAltValue::clone() const
{
return AutoPtr(clone_());
}
示例2: switch
Value::AutoPtr Value::create(TypeId typeId)
{
AutoPtr value;
switch (typeId) {
case invalidTypeId:
case signedByte:
case unsignedByte:
value = AutoPtr(new DataValue(typeId));
break;
case asciiString:
value = AutoPtr(new AsciiValue);
break;
case unsignedShort:
value = AutoPtr(new ValueType<uint16_t>);
break;
case unsignedLong:
case tiffIfd:
value = AutoPtr(new ValueType<uint32_t>(typeId));
break;
case unsignedRational:
value = AutoPtr(new ValueType<URational>);
break;
case undefined:
value = AutoPtr(new DataValue);
break;
case signedShort:
value = AutoPtr(new ValueType<int16_t>);
break;
case signedLong:
value = AutoPtr(new ValueType<int32_t>);
break;
case signedRational:
value = AutoPtr(new ValueType<Rational>);
break;
case tiffFloat:
value = AutoPtr(new ValueType<float>);
break;
case tiffDouble:
value = AutoPtr(new ValueType<double>);
break;
case string:
value = AutoPtr(new StringValue);
break;
case date:
value = AutoPtr(new DateValue);
break;
case time:
value = AutoPtr(new TimeValue);
break;
case comment:
value = AutoPtr(new CommentValue);
break;
case xmpText:
value = AutoPtr(new XmpTextValue);
break;
case xmpBag:
case xmpSeq:
case xmpAlt:
value = AutoPtr(new XmpArrayValue(typeId));
break;
case langAlt:
value = AutoPtr(new LangAltValue);
break;
default:
value = AutoPtr(new DataValue(typeId));
break;
}
return value;
} // Value::create
示例3: AutoPtr
Key::AutoPtr Key::clone() const
{
return AutoPtr(clone_());
}
示例4: AutoPtr
FujiMakerNote::AutoPtr FujiMakerNote::clone() const
{
return AutoPtr(clone_());
}
示例5: AutoPtr
FujiMakerNote::AutoPtr FujiMakerNote::clone(bool alloc) const
{
return AutoPtr(clone_(alloc));
}