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


C# PdfObject.IsNull方法代码示例

本文整理汇总了C#中PdfObject.IsNull方法的典型用法代码示例。如果您正苦于以下问题:C# PdfObject.IsNull方法的具体用法?C# PdfObject.IsNull怎么用?C# PdfObject.IsNull使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在PdfObject的用法示例。


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

示例1: AddDefaultColor

 internal void AddDefaultColor(PdfName name, PdfObject obj)
 {
     if (obj == null || obj.IsNull())
         colorDictionary.Remove(name);
     else
         colorDictionary.Put(name, obj);
 }
开发者ID:pixelia-es,项目名称:RazorPDF2,代码行数:7,代码来源:PageResources.cs

示例2: SetDefaultColorspace

 /**
 * Sets the default colorspace that will be applied to all the document.
 * The colorspace is only applied if another colorspace with the same name
 * is not present in the content.
 * <p>
 * The colorspace is applied immediately when creating templates and at the page
 * end for the main document content.
 * @param key the name of the colorspace. It can be <CODE>PdfName.DEFAULTGRAY</CODE>, <CODE>PdfName.DEFAULTRGB</CODE>
 * or <CODE>PdfName.DEFAULTCMYK</CODE>
 * @param cs the colorspace. A <CODE>null</CODE> or <CODE>PdfNull</CODE> removes any colorspace with the same name
 */
 public void SetDefaultColorspace(PdfName key, PdfObject cs)
 {
     if (cs == null || cs.IsNull())
         defaultColorspace.Remove(key);
     defaultColorspace.Put(key, cs);
 }
开发者ID:pixelia-es,项目名称:RazorPDF2,代码行数:17,代码来源:PdfWriter.cs

示例3: Put

 // methods concerning the Hashtable member value
 /**
  * Adds a <CODE>PdfObject</CODE> and its key to the <CODE>PdfDictionary</CODE>.
  * If the value is <CODE>null</CODE> or <CODE>PdfNull</CODE> the key is deleted.
  *
  * @param        key        key of the entry (a <CODE>PdfName</CODE>)
  * @param        value    value of the entry (a <CODE>PdfObject</CODE>)
  */
 public void Put(PdfName key, PdfObject value)
 {
     if (value == null || value.IsNull())
         hashMap.Remove(key);
     else
         hashMap[key] = value;
 }
开发者ID:pixelia-es,项目名称:RazorPDF2,代码行数:15,代码来源:PdfDictionary.cs


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