当前位置: 首页>>代码示例>>C++>>正文


C++ CFX_ByteStringC类代码示例

本文整理汇总了C++中CFX_ByteStringC的典型用法代码示例。如果您正苦于以下问题:C++ CFX_ByteStringC类的具体用法?C++ CFX_ByteStringC怎么用?C++ CFX_ByteStringC使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。


在下文中一共展示了CFX_ByteStringC类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。

示例1: RemoveAt

void CXML_AttrMap::RemoveAt(const CFX_ByteStringC& space, const CFX_ByteStringC& name)
{
    if (m_pMap == NULL) {
        return;
    }
    for (int i = 0; i < m_pMap->GetSize(); i ++) {
        CXML_AttrItem& item = GetAt(i);
        if ((space.IsEmpty() || item.m_QSpaceName == space) && item.m_AttrName == name) {
            m_pMap->RemoveAt(i);
            return;
        }
    }
}
开发者ID:abbro-ca,项目名称:pdfium,代码行数:13,代码来源:fx_xml_parser.cpp

示例2:

FX_BOOL CFXCRT_FileAccess_Win64::Open(const CFX_ByteStringC& fileName,
                                      uint32_t dwMode) {
  if (m_hFile) {
    return FALSE;
  }
  uint32_t dwAccess, dwShare, dwCreation;
  FXCRT_Windows_GetFileMode(dwMode, dwAccess, dwShare, dwCreation);
  m_hFile = ::CreateFileA(fileName.c_str(), dwAccess, dwShare, nullptr,
                          dwCreation, FILE_ATTRIBUTE_NORMAL, nullptr);
  if (m_hFile == INVALID_HANDLE_VALUE)
    m_hFile = nullptr;
  return !!m_hFile;
}
开发者ID:hfiguiere,项目名称:pdfium,代码行数:13,代码来源:fxcrt_windows.cpp

示例3:

FX_BOOL CFXCRT_FileAccess_Win64::Open(const CFX_ByteStringC& fileName,
                                      FX_DWORD dwMode) {
  if (m_hFile) {
    return FALSE;
  }
  FX_DWORD dwAccess, dwShare, dwCreation;
  FXCRT_Windows_GetFileMode(dwMode, dwAccess, dwShare, dwCreation);
  m_hFile = ::CreateFileA(fileName.GetCStr(), dwAccess, dwShare, NULL,
                          dwCreation, FILE_ATTRIBUTE_NORMAL, NULL);
  if (m_hFile == INVALID_HANDLE_VALUE) {
    m_hFile = NULL;
  }
  return m_hFile != NULL;
}
开发者ID:hoanganhx86,项目名称:pdfium,代码行数:14,代码来源:fxcrt_windows.cpp

示例4: CountElements

uint32_t CXML_Element::CountElements(const CFX_ByteStringC& space,
                                     const CFX_ByteStringC& tag) const {
  int count = 0;
  for (const ChildRecord& record : m_Children) {
    if (record.type != Element)
      continue;

    CXML_Element* pKid = static_cast<CXML_Element*>(record.child);
    if ((space.IsEmpty() || pKid->m_QSpaceName == space) &&
        pKid->m_TagName == tag) {
      count++;
    }
  }
  return count;
}
开发者ID:documentcloud,项目名称:pdfium,代码行数:15,代码来源:fx_xml_parser.cpp

示例5: CountElements

FX_DWORD CXML_Element::CountElements(const CFX_ByteStringC& space, const CFX_ByteStringC& tag) const
{
    int count = 0;
    for (int i = 0; i < m_Children.GetSize(); i += 2) {
        ChildType type = (ChildType)(uintptr_t)m_Children.GetAt(i);
        if (type != Element) {
            continue;
        }
        CXML_Element* pKid = (CXML_Element*)m_Children.GetAt(i + 1);
        if ((space.IsEmpty() || pKid->m_QSpaceName == space) && pKid->m_TagName == tag) {
            count ++;
        }
    }
    return count;
}
开发者ID:abbro-ca,项目名称:pdfium,代码行数:15,代码来源:fx_xml_parser.cpp

示例6: GetNamespaceURI

CFX_ByteString CXML_Element::GetNamespaceURI(const CFX_ByteStringC& qName) const
{
    const CFX_WideString* pwsSpace;
    const CXML_Element *pElement = this;
    do {
        if (qName.IsEmpty()) {
            pwsSpace = pElement->m_AttrMap.Lookup(FX_BSTRC(""), FX_BSTRC("xmlns"));
        } else {
            pwsSpace = pElement->m_AttrMap.Lookup(FX_BSTRC("xmlns"), qName);
        }
        if (pwsSpace) {
            break;
        }
        pElement = pElement->GetParent();
    } while(pElement);
    return pwsSpace ? FX_UTF8Encode(*pwsSpace) : CFX_ByteString();
}
开发者ID:abbro-ca,项目名称:pdfium,代码行数:17,代码来源:fx_xml_parser.cpp

示例7: SetAt

void CXML_AttrMap::SetAt(const CFX_ByteStringC& space, const CFX_ByteStringC& name, const CFX_WideStringC& value)
{
    for (int i = 0; i < GetSize(); i++) {
        CXML_AttrItem& item = GetAt(i);
        if ((space.IsEmpty() || item.m_QSpaceName == space) && item.m_AttrName == name) {
            item.m_Value = value;
            return;
        }
    }
    if (!m_pMap) {
        m_pMap = new CFX_ObjectArray<CXML_AttrItem>;
    }
    CXML_AttrItem* pItem = (CXML_AttrItem*)m_pMap->AddSpace();
    if (!pItem) {
        return;
    }
    pItem->m_QSpaceName = space;
    pItem->m_AttrName = name;
    pItem->m_Value = value;
}
开发者ID:abbro-ca,项目名称:pdfium,代码行数:20,代码来源:fx_xml_parser.cpp

示例8: FX_XML_SplitQualifiedName

void FX_XML_SplitQualifiedName(const CFX_ByteStringC& bsFullName,
                               CFX_ByteStringC& bsSpace,
                               CFX_ByteStringC& bsName) {
  if (bsFullName.IsEmpty()) {
    return;
  }
  int32_t iStart = 0;
  for (; iStart < bsFullName.GetLength(); iStart++) {
    if (bsFullName.GetAt(iStart) == ':') {
      break;
    }
  }
  if (iStart >= bsFullName.GetLength()) {
    bsName = bsFullName;
  } else {
    bsSpace = CFX_ByteStringC(bsFullName.GetCStr(), iStart);
    iStart++;
    bsName = CFX_ByteStringC(bsFullName.GetCStr() + iStart,
                             bsFullName.GetLength() - iStart);
  }
}
开发者ID:primiano,项目名称:pdfium-merge,代码行数:21,代码来源:fx_xml_composer.cpp

示例9: FX_File_Move

FX_BOOL FX_File_Move(const CFX_ByteStringC& fileNameSrc,
                     const CFX_ByteStringC& fileNameDst) {
  return ::MoveFileA(fileNameSrc.GetCStr(), fileNameDst.GetCStr());
}
开发者ID:hoanganhx86,项目名称:pdfium,代码行数:4,代码来源:fxcrt_windows.cpp

示例10: FX_File_Copy

FX_BOOL FX_File_Copy(const CFX_ByteStringC& fileNameSrc,
                     const CFX_ByteStringC& fileNameDst) {
  return ::CopyFileA(fileNameSrc.GetCStr(), fileNameDst.GetCStr(), FALSE);
}
开发者ID:hoanganhx86,项目名称:pdfium,代码行数:4,代码来源:fxcrt_windows.cpp

示例11: FX_File_Delete

FX_BOOL FX_File_Delete(const CFX_ByteStringC& fileName) {
  return ::DeleteFileA(fileName.GetCStr());
}
开发者ID:hoanganhx86,项目名称:pdfium,代码行数:3,代码来源:fxcrt_windows.cpp

示例12: XFA_ByteStringToDouble

FX_DOUBLE XFA_ByteStringToDouble(const CFX_ByteStringC& szStringVal) {
  CFX_WideString wsValue =
      CFX_WideString::FromUTF8(szStringVal.GetCStr(), szStringVal.GetLength());
  return XFA_WideStringToDouble(wsValue);
}
开发者ID:andoma,项目名称:pdfium,代码行数:5,代码来源:xfa_utils_imp.cpp

示例13: CheckWord

bool CXFA_FFTextEdit::CheckWord(const CFX_ByteStringC& sWord) {
  if (sWord.IsEmpty() || m_pDataAcc->GetUIType() != XFA_Element::TextEdit)
    return true;
  return false;
}
开发者ID:documentcloud,项目名称:pdfium,代码行数:5,代码来源:xfa_fftextedit.cpp

示例14: CheckWord

FX_BOOL CXFA_FFTextEdit::CheckWord(const CFX_ByteStringC& sWord) {
  if (sWord.IsEmpty() || m_pDataAcc->GetUIType() != XFA_ELEMENT_TextEdit) {
    return TRUE;
  }
  return GetDoc()->GetDocProvider()->CheckWord(GetDoc(), sWord);
}
开发者ID:primiano,项目名称:pdfium-merge,代码行数:6,代码来源:xfa_fftextedit.cpp

示例15: CopyData

void CFX_ByteTextBuf::operator =(const CFX_ByteStringC& str)
{
    CopyData((FX_LPCBYTE)str, str.GetLength());
}
开发者ID:151706061,项目名称:PDFium,代码行数:4,代码来源:fx_basic_buffer.cpp


注:本文中的CFX_ByteStringC类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。