Exemplo n.º 1
0
 private void Dispose(bool bDisposing)
 {
     if (!Disposed)
     {
         Disposed = true;
         if (_chunk != null)
         {
             _chunk.Dispose();
             _chunk = null;
         }
         if (_text != null)
         {
             _text.Dispose();
             _text = null;
         }
         _html = null;
         if (_e != null)
         {
             _e.Dispose();
             _e = null;
         }
         if (_tp != null)
         {
             _tp.Dispose();
             _tp = null;
         }
     }
 }
Exemplo n.º 2
0
 /// <summary>
 /// Inits tag parser
 /// </summary>
 /// <param name="chunk"></param>
 /// <param name="text"></param>
 internal void Init(HTMLparser p, HTMLchunk chunk, DynaString text, byte[] html, int dataLength, HTMLentities e, HTMLheuristics he)
 {
     _p          = p;
     _chunk      = chunk;
     _text       = text;
     _html       = html;
     _dataLength = dataLength;
     // we don't want to be too close to end of data when dealing with heuristics
     _maxHeuDataLength = _dataLength - MIN_DATA_SIZE_FOR_HEURISTICS;
     _e  = e;
     _he = he;
 }
Exemplo n.º 3
0
 /// <summary>
 /// This function will decode any entities found in a string - not fast!
 /// </summary>
 /// <returns>Possibly decoded string</returns>
 public static string DecodeEntities(string data)
 {
     return(HTMLentities.DecodeEntities(data));
 }