다음을 통해 공유


DataDefinitionType 복합 형식

이벤트에 포함할 데이터 항목을 정의합니다.

<xs:complexType name="DataDefinitionType"
    mixed="true"
>
    <xs:simpleContent>
        <xs:extension
            base="string"
        >
            <xs:attribute name="name"
                type="string"
                use="required"
             />
            <xs:attribute name="inType"
                type="QName"
                use="required"
             />
            <xs:attribute name="outType"
                type="QName"
                use="optional"
             />
            <xs:attribute name="map"
                type="string"
                use="optional"
             />
            <xs:attribute name="length"
                type="LengthType"
                use="optional"
             />
            <xs:attribute name="count"
                type="CountType"
                use="optional"
             />
            <xs:anyAttribute
                processContents="lax"
                namespace="##other"
             />
        </xs:extension>
    </xs:simpleContent>
</xs:complexType>

특성

이름 형식 설명
개수 CountType 데이터 항목이 배열인 경우 배열의 요소 수입니다. 실제 개수 또는 개수가 포함된 다른 데이터 항목의 이름을 지정할 수 있습니다.
inType QName 이 데이터 항목의 데이터 형식입니다. 미리 정의된 입력 데이터 형식 목록은 InputType 복합 형식을 참조하세요.
length LengthType 이진 Blob과 같은 가변 길이 데이터 항목의 길이입니다. 이진 데이터의 경우 길이를 바이트 단위로 지정하고 문자열 데이터의 경우 길이를 문자로 지정합니다. 실제 길이 또는 길이를 포함하는 다른 데이터 항목의 이름을 지정할 수 있습니다.
length 특성을 사용하여 고정 길이 문자열을 지정하는 경우 끝에 null 종결자 문자가 허용되도록 문자열을 고정 길이로 패딩해야 합니다(예: 길이가 5인 경우 문자열 "abc"는 "abc"로 패딩되어야 합니다. 문자열 길이에는 null 종결자 문자가 포함되어야 합니다.
map 문자열 정수 값을 문자열에 매핑하는 데 사용할 이름/값 맵의 이름입니다. 데이터 항목의 데이터 형식은 다음 형식 중 하나여야 합니다.
  • win:UInt8
  • win:UInt16
  • win:UInt32
name 문자열 데이터 항목의 이름입니다. 템플릿에서 UserData 섹션을 지정하는 경우 이름을 사용하여 XML 조각에서 이 데이터 항목을 참조할 수 있습니다. 이 데이터 항목에 길이 또는 개수 값이 포함된 경우 다른 데이터 항목의 길이 또는 개수 특성으로 이 이름을 참조할 수도 있습니다.
Windows Vista: 이 특성은 선택 사항입니다.
outType QName 이 데이터 항목을 렌더링할 때 사용할 데이터 형식입니다. 미리 정의된 출력 데이터 형식 목록은 OutputType 복합 형식을 참조하세요.
Windows Vista: 출력 형식은 무시되고 서비스는 입력 형식에 따라 형식을 결정합니다.

설명

이진 Blob과 같은 가변 길이 입력 형식의 경우 length 특성을 사용하여 데이터의 크기를 명시적으로 지정해야 합니다. 문자열의 경우 문자열이 고정 길이인 경우에만 length 특성을 지정합니다.

예제

다음은 데이터 항목 정의의 몇 가지 예입니다.

<!-- The data item is an 8-bit integer -->
<data name="binaryChar" inType="win:UInt8">
 
<!-- The data item is a single ANSI character -->
<data name="ansiChar" inType="win:UInt8" outtype="xs:string">
 
<!-- The data item is a single Unicode character -->
<data name="unicodeChar" inType="win:UInt16" outtype="xs:string">
 
<!-- The data item is an IP address that is rendered as a dot separated list of interger values -->
<data name="ipAddress" inType="win:UInt32" outtype="win:IPv4">
 
<!-- The data item is a Boolean value -->
<data name="success" inType="win:boolean">
 
<!-- The data item is a null-terminated ANSI string -->
<data name="string" inType="win:AnsiString"> 

<!-- The data item is a fixed length ANSI string -->
<data name="string" inType="win:AnsiString" length="42"> 
 
<!-- The data item is a fixed length array of null-terminated ANSI strings -->
<data name="strings" inType="win:AnsiString" count="20">
 
<!-- The data item is a fixed length array of fixed length ANSI strings -->
<data name="strings" inType="win:AnsiString" length="42" count="20">
 
<!-- The data item is a variable length array of same sized ANSI strings -->
<data name="stringLength" inType="win:UInt16">
<data name="arrayCount" inType="win:Uint16">
<data name="strings" inType="win:AnsiString" length="stringLength" count="arrayCount"> 
 
<!-- For binary data, you must specify the size.
<!-- The data item is a fixed length array of fixed length binary blobs -->
<data name="blobs" inType="win:Binary" length="42" count="20">

<!-- The data item is a fixed length binary blob -->
<data name="blob" inType="win:Binary" length="42">

<!-- The following are illegal binary data definitions -->
<!-- This definition is illegal because no length is specified -->
<data name="blob" inType="win:Binary"> 
 
<!-- This definition is illegal because you cannot determine the length of each binary blob -->
<data name="blob" inType="win:Binary" count="20"> 
 
<!-- The data item is a variable length array of structures. Each structure -->
<!-- contains an array of same sized ANSI strings --> 
<data name="arrayStructCount" inType="win:UInt16">
<struct name="countedStrings" count="arrayStructCount">
      <data name="stringLength" inType="win:UInt16">
      <data name="string" inType="win:AnsiString" length="stringLength">
</struct>
 
<!-- The data item is a time stamp that is rendered in 100ns units -->
<data name="timestamp" inType="win:UInt32" outType="win:ETWTIME">

<!-- The data item is a fixed length array of integers --> 
<data name="integers" inType="win:UInt32" count="20">

<!-- The data item is a variable length array of integers -->
<data name="arrayCount" inType="win:UInt16"> 
<data name="integers" inType="win:UInt32" count="arrayCount"> 

<!-- The following is illegal because you cannot assign a length value to a data type of a known size -->
<data name="integer" inType="win:UInt32" length="42">

요구 사항

요구 사항
지원되는 최소 클라이언트
Windows Vista [데스크톱 앱만 해당]
지원되는 최소 서버
Windows Server 2008 [데스크톱 앱만 해당]