/// <summary> /// Create a new CefXmlReader object. /// The returned object's methods can only be called from the thread that created the object. /// </summary> public static CefXmlReader Create(CefStreamReader stream, CefXmlEncodingType encodingType, string uri) { fixed (char* uri_str = uri) { var n_uri = new cef_string_t(uri_str, uri != null ? uri.Length : 0); return CefXmlReader.From( NativeMethods.cef_xml_reader_create( stream.GetNativePointerAndAddRef(), (cef_xml_encoding_type_t)encodingType, &n_uri) ); } }
/// <summary> /// Create a new CefXmlReader object. /// The returned object's methods can only be called from the thread that created the object. /// </summary> public static CefXmlReader Create(CefStreamReader stream, CefXmlEncodingType encodingType, string uri) { fixed(char *uri_str = uri) { var n_uri = new cef_string_t(uri_str, uri != null ? uri.Length : 0); return(CefXmlReader.From( NativeMethods.cef_xml_reader_create( stream.GetNativePointerAndAddRef(), (cef_xml_encoding_type_t)encodingType, &n_uri) )); } }
public static cef_xml_reader_t *Create(CefStreamReader reader, CefXmlEncodingType encodingType, string uri) { if (reader == null) throw new ArgumentNullException(nameof(reader)); fixed(char *s0 = uri) { var cstr0 = new cef_string_t { Str = s0, Length = (uri != null ? uri.Length : 0) }; return(CefNativeApi.cef_xml_reader_create(reader.GetNativeInstance(), encodingType, &cstr0)); } }
/// <summary> /// Create a new CefXmlReader object. /// The returned object's methods can only be called from the thread that created the object. /// </summary> public static CefXmlReader Create(CefStreamReader stream, CefXmlEncodingType encodingType, Uri uri) { return Create(stream, encodingType, uri.ToString()); }
/// <summary> /// Create a new cef_zip_reader_t object. The created instance can /// only be used from the thread that created the object. /// </summary> public CefZipReader(CefStreamReader reader, CefXmlEncodingType encodingType, string uri) : this(CefNativeApi.cef_zip_reader_create((reader ?? throw new ArgumentNullException(nameof(reader))).GetNativeInstance()))
/// <summary> /// Create a new CefXmlReader object. /// The returned object's methods can only be called from the thread that created the object. /// </summary> public static CefXmlReader Create(CefStreamReader stream, CefXmlEncodingType encodingType, Uri uri) { return(Create(stream, encodingType, uri.ToString())); }
/// <summary> /// Create a new cef_xml_reader_t object. The created instance can /// only be used from the thread that created the object. /// </summary> public CefXmlReader(CefStreamReader reader, CefXmlEncodingType encodingType, string uri) : this(Create(reader, encodingType, uri)) { }