Exemplo n.º 1
0
 /// <summary>
 /// This method is a helper function to quickly create dynamic stream
 /// descriptions needed to register a new dynamic stream. The
 /// descriptions contains information about the stream's name, layout,
 /// and operations. This method uses the supplied type information.
 /// </summary>
 /// <param name="name">A friendly name of the new stream (e.g.,
 ///     "Filtered memory accesses").</param>
 /// <param name="userData">Pointer to a valid StreamTypeDescriptor
 ///     structure, defining the desired type of the new stream.</param>
 /// <param name="type">A pointer to optional user-defined data that
 ///     should be available when the stream is opened. The data
 ///     must not be freed for the lifetime of the stream.</param>
 /// <param name="operations">Pointer to a set of operations that
 ///     implement the logic of the dynamic stream.</param>
 /// <param name="descOut">Pointer to a DynamicStreamDescriptor
 ///     structure that will</param>
 /// <returns>true if successful, false otherwise. For a more detailed
 ///     error description call StGetLastError().</returns>
 public static bool StMakeStreamDescriptorDynamicFromType(string name,
                                                          IntPtr userData, ref StreamTypeDescriptor type,
                                                          ref DynamicStreamOperations operations,
                                                          out DynamicStreamDescriptor descOut)
 {
     return(NativeMethods.StMakeStreamDescriptorDynamicFromType(name,
                                                                userData, ref type, ref operations, out descOut));
 }
Exemplo n.º 2
0
 /// <summary>
 /// This method is a helper function to quickly create a new stream
 /// description needed to register a new stream. The description
 /// contains information about the stream's name and layout of trace
 /// entries, that is records written to or read from a stream. This
 /// method uses the supplied type information.
 /// </summary>
 /// <param name="name">A friendly name of the new stream (e.g.,
 ///     "CPU Memory Accesses").</param>
 /// <param name="type">Reference to a valid StreamTypeDescriptor
 ///     structure, defining the desired type of the new stream.</param>
 /// <param name="descOut">StreamDescriptor structure that will
 ///     receive the new stream information.</param>
 /// <returns>true if successful, false otherwise. For a more
 ///     detailed error description call StGetLastError().</returns>
 public static bool StMakeStreamDescriptorFromType(string name,
                                                   ref StreamTypeDescriptor type, out StreamDescriptor descOut)
 {
     return(NativeMethods.StMakeStreamDescriptorFromType(name, ref type,
                                                         out descOut));
 }
Exemplo n.º 3
0
 public static extern bool StMakeStreamDescriptorDynamicFromType(
     string name, IntPtr userData, ref StreamTypeDescriptor type,
     ref DynamicStreamOperations operations,
     out DynamicStreamDescriptor descOut);
Exemplo n.º 4
0
 /// <summary>
 /// This method extracts the entry size of the supplied stream type.
 /// For variable-sized stream types it will return the size hint as
 /// given to MakeVariableEntrySize().
 /// </summary>
 /// <param name="desc">stream type description from which to read
 ///     the entry size.</param>
 /// <returns>The entry size of the given stream type.</returns>
 public static uint GetEntrySize(ref StreamTypeDescriptor desc)
 {
     return(desc.entrySize & (~VARIABLE_ENTRY_SIZE_FLAG));
 }
Exemplo n.º 5
0
 public static extern bool StMakeStreamDescriptorFromType(
     string name, ref StreamTypeDescriptor type,
     out StreamDescriptor descOut);