Ejemplo n.º 1
0
 /// <summary>
 /// Creates new HSSFName   - called by HSSFWorkbook to Create a sheet from
 /// scratch.
 /// </summary>
 /// <param name="book">lowlevel Workbook object associated with the sheet.</param>
 /// <param name="name">the Name Record</param>
 /// <param name="comment"></param>
 internal HSSFName(HSSFWorkbook book, NameRecord name, NameCommentRecord comment)
 {
     this.book = book;
     this._definedNameRec = name;
     _commentRec = comment;
 }
Ejemplo n.º 2
0
 /**
  * If a {@link NameCommentRecord} is added or the name it references
  *  is renamed, then this will update the lookup cache for it.
  */
 public void UpdateNameCommentRecordCache(NameCommentRecord commentRecord)
 {
     if (commentRecords.ContainsValue(commentRecord))
     {
         foreach (KeyValuePair<string, NameCommentRecord> entry in commentRecords)
         {
             if (entry.Value.Equals(commentRecord))
             {
                 commentRecords.Remove(entry.Key);
                 break;
             }
         }
     }
     commentRecords[commentRecord.NameText] = commentRecord;
 }