LibreOffice Module basic (master) 1
|
#include <image.hxx>
Public Member Functions | |
SbiImage () | |
~SbiImage () | |
void | Clear () |
bool | Load (SvStream &, sal_uInt32 &nVer) |
bool | Save (SvStream &, sal_uInt32) |
bool | IsError () const |
const sal_uInt8 * | GetCode () const |
sal_uInt32 | GetCodeSize () const |
sal_uInt16 | GetBase () const |
OUString | GetString (sal_uInt32 nId, SbxDataType *eType=nullptr) const |
const SbxObject * | FindType (const OUString &aTypeName) const |
const SbxArrayRef & | GetEnums () const |
void | SetFlag (SbiImageFlags n) |
bool | IsFlag (SbiImageFlags n) const |
sal_uInt16 | CalcLegacyOffset (sal_Int32 nOffset) |
sal_uInt32 | CalcNewOffset (sal_Int16 nOffset) |
void | ReleaseLegacyBuffer () |
bool | ExceedsLegacyLimits () |
bool | ExceedsImgVersion12Limits () |
Public Attributes | |
OUString | aName |
OUString | aOUSource |
OUString | aComment |
bool | bInit |
bool | bFirstInit |
Private Member Functions | |
void | MakeStrings (short) |
void | AddString (const OUString &) |
void | AddCode (std::vector< sal_uInt8 > &&) |
void | AddType (SbxObject const *) |
void | AddEnum (SbxObject *) |
Private Attributes | |
SbxArrayRef | rTypes |
SbxArrayRef | rEnums |
std::vector< sal_uInt32 > | mvStringOffsets |
std::unique_ptr< sal_Unicode[]> | pStrings |
std::vector< sal_uInt8 > | aCode |
std::vector< sal_uInt8 > | aLegacyPCode |
bool | bError |
SbiImageFlags | nFlags |
sal_uInt32 | nStringSize |
sal_uInt16 | nDimBase |
rtl_TextEncoding | eCharSet |
std::size_t | nStringIdx |
sal_uInt32 | nStringOff |
Friends | |
class | SbiCodeGen |
|
private |
|
private |
Definition at line 608 of file image.cxx.
References tools::SvRef< typename T >::is(), pObject, and rEnums.
|
private |
Definition at line 551 of file image.cxx.
References bError, mvStringOffsets, nStringIdx, nStringOff, nStringSize, p, and pStrings.
|
private |
sal_uInt16 SbiImage::CalcLegacyOffset | ( | sal_Int32 | nOffset | ) |
Definition at line 670 of file image.cxx.
References aCode, and SbiCodeGen::calcLegacyOffSet().
Referenced by ExceedsImgVersion12Limits(), ExceedsLegacyLimits(), and SbModule::fixUpMethodStart().
sal_uInt32 SbiImage::CalcNewOffset | ( | sal_Int16 | nOffset | ) |
Definition at line 675 of file image.cxx.
References aLegacyPCode, and SbiCodeGen::calcNewOffSet().
Referenced by SbModule::fixUpMethodStart().
void SbiImage::Clear | ( | ) |
Definition at line 51 of file image.cxx.
References aCode, aLegacyPCode, bError, eCharSet, mvStringOffsets, nDimBase, nFlags, NONE, nStringSize, and pStrings.
Referenced by Load().
bool SbiImage::ExceedsImgVersion12Limits | ( | ) |
Definition at line 690 of file image.cxx.
References aCode, CalcLegacyOffset(), and nStringSize.
bool SbiImage::ExceedsLegacyLimits | ( | ) |
Definition at line 685 of file image.cxx.
References aCode, CalcLegacyOffset(), and nStringSize.
const SbxObject * SbiImage::FindType | ( | const OUString & | aTypeName | ) | const |
Definition at line 665 of file image.cxx.
References tools::SvRef< typename T >::is(), Object, and rTypes.
|
inline |
|
inline |
Definition at line 85 of file image.hxx.
References aCode.
Referenced by SbModule::FindNextStmnt(), SbiRuntime::SbiRuntime(), SbiRuntime::StepGOSUB(), SbiRuntime::StepJUMP(), and SbiRuntime::StepONJUMP().
|
inline |
Definition at line 86 of file image.hxx.
References aCode.
Referenced by SbiRuntime::StepGOSUB(), and SbiRuntime::StepJUMP().
|
inline |
OUString SbiImage::GetString | ( | sal_uInt32 | nId, |
SbxDataType * | eType = nullptr |
||
) | const |
Definition at line 618 of file image.cxx.
References eType, o3tl::make_unsigned(), mvStringOffsets, nId, nStringSize, pStrings, SbxCURRENCY, SbxDOUBLE, SbxINTEGER, SbxLONG, SbxSINGLE, SbxSTRING, and u.
Referenced by SbiRuntime::FindElement(), SbiRuntime::StepARGN(), SbiRuntime::StepCALL(), SbiRuntime::StepCALLC(), SbiRuntime::StepCREATE(), SbiRuntime::StepDCREATE_IMPL(), SbiRuntime::StepFIND_G(), SbiRuntime::StepGLOBAL(), SbiRuntime::StepLIB(), SbiRuntime::StepLOADNC(), SbiRuntime::StepLOADSC(), SbiRuntime::StepLOCAL(), SbiRuntime::StepPARAM(), SbiRuntime::StepPUBLIC_Impl(), SbiRuntime::StepSETCLASS_impl(), SbiRuntime::StepSTATIC(), SbiRuntime::StepTCREATE(), and SbiRuntime::StepTESTCLASS().
|
inline |
Definition at line 94 of file image.hxx.
Referenced by SbiRuntime::FindElement(), SbiRuntime::IsImageFlag(), SbiRuntime::StepGLOBAL(), and SbiRuntime::StepPUBLIC_P().
bool SbiImage::Load | ( | SvStream & | r, |
sal_uInt32 & | nVer | ||
) |
Definition at line 103 of file image.cxx.
References aCode, aComment, AddType(), aLegacyPCode, aName, aOUSource, aStr, B_IMG_VERSION_12, B_IMG_VERSION_13, bError, Clear(), cloneTypeObjectImpl(), Comment, PCodeBuffConvertor< T, S >::convert(), SbxArray::Count(), d, DontCare, eCharSet, ERRCODE_NONE, ExtSource, Fixed, tools::SvRef< typename T >::get(), PCodeBuffConvertor< T, S >::GetBuffer(), SvStream::GetError(), SbxBase::GetFlags(), SbxObject::GetProperties(), GetSOLoadTextEncoding(), GetToUnicodePoolData(), SvStream::good(), i, SbxArray::Insert(), LineRanges, MakeStrings(), ModEnd, Module, mvStringOffsets, Name, nCount, nDimBase, nFlags, nStringSize, nVersion, Object, PCode, PoolDir, pStrings, Publics, SbxValue::PutObject(), read_uInt16s_ToOUString(), SvStream::ReadBytes(), SvStream::ReadInt16(), SvStream::ReadInt32(), SvStream::ReadUInt16(), SvStream::ReadUInt32(), SvStream::ReadUniOrByteString(), SvStream::remainingSize(), SbxObject::Remove(), SbxBase::ResetFlag(), rTypes, SAL_WARN, SbxOBJECT, SvStream::Seek(), SbxBase::SetFlags(), SbxDimArray::setHasFixedSize(), Source, StringPool, SymPool, SvStream::Tell(), SbxDimArray::unoAddDim(), and UserTypes.
|
private |
Definition at line 536 of file image.cxx.
References mvStringOffsets, nStringIdx, nStringOff, nStringSize, and pStrings.
Referenced by Load().
void SbiImage::ReleaseLegacyBuffer | ( | ) |
Definition at line 680 of file image.cxx.
References aLegacyPCode.
bool SbiImage::Save | ( | SvStream & | r, |
sal_uInt32 | nVer | ||
) |
Definition at line 374 of file image.cxx.
References aCode, aComment, aName, aOUSource, aStr, bError, Comment, SbxArray::Count(), d, eCharSet, SbxArray::Get(), SbxObject::GetClassName(), SbxDimArray::GetDim(), SbxDimArray::GetDims(), SbxBase::GetFlags(), SbxVariable::GetName(), SbxValue::GetObject(), SbxObject::GetProperties(), GetSOStoreTextEncoding(), SbxVariable::GetType(), SvStream::good(), SbxDimArray::hasFixedSize(), i, tools::SvRef< typename T >::is(), Module, mvStringOffsets, Name, nDimBase, nFlags, nPos, nStringSize, nUnicodeDataMagicNumber, OUStringToOString(), PCode, pStrings, rTypes, SbiCloseRecord(), SbiOpenRecord(), SbxOBJECT, Source, StringPool, UserTypes, write_uInt16s_FromOUString(), SvStream::WriteBytes(), SvStream::WriteInt16(), SvStream::WriteInt32(), SvStream::WriteUInt32(), and SvStream::WriteUniOrByteString().
Referenced by SbModule::StoreData().
|
inline |
|
friend |
|
private |
Definition at line 52 of file image.hxx.
Referenced by AddCode(), CalcLegacyOffset(), Clear(), ExceedsImgVersion12Limits(), ExceedsLegacyLimits(), GetCode(), GetCodeSize(), Load(), and Save().
OUString SbiImage::aComment |
Definition at line 72 of file image.hxx.
Referenced by Load(), Save(), and SbModule::StoreData().
|
private |
Definition at line 53 of file image.hxx.
Referenced by CalcNewOffset(), Clear(), Load(), and ReleaseLegacyBuffer().
OUString SbiImage::aName |
Definition at line 70 of file image.hxx.
Referenced by Load(), Save(), and SbModule::StoreData().
OUString SbiImage::aOUSource |
Definition at line 71 of file image.hxx.
Referenced by Load(), Save(), and SbModule::StoreData().
|
private |
|
private |
|
private |
Definition at line 50 of file image.hxx.
Referenced by AddString(), Clear(), GetString(), Load(), MakeStrings(), and Save().
|
private |
|
private |
|
private |
Definition at line 60 of file image.hxx.
Referenced by AddString(), and MakeStrings().
|
private |
Definition at line 61 of file image.hxx.
Referenced by AddString(), and MakeStrings().
|
private |
Definition at line 56 of file image.hxx.
Referenced by AddString(), Clear(), ExceedsImgVersion12Limits(), ExceedsLegacyLimits(), GetString(), Load(), MakeStrings(), and Save().
|
private |
Definition at line 51 of file image.hxx.
Referenced by AddString(), Clear(), GetString(), Load(), MakeStrings(), and Save().
|
private |
Definition at line 49 of file image.hxx.
Referenced by AddEnum(), and GetEnums().
|
private |