Skip to main content

Search OfficeIMO

Enter a topic, API type, or PowerShell command.

Documentation Search all OfficeIMO/
Class

MapiPropertyExtensions

OfficeIMO.Email

Namespace
OfficeIMO.Email
Assembly
OfficeIMO.Email
Source revision
c47203b3ce89 with working tree changes
Modifiers
static

Convenience lookup APIs for retained standard and named MAPI properties.

Inheritance

  • object
  • MapiPropertyExtensions

Methods

GetMapiProperty 4 overloads
public static MapiProperty? GetMapiProperty(IEnumerable<MapiProperty> properties, MapiPropertyKey key) #

Finds the last property matching a typed key's identity and accepted wire types.

Parameters

properties System.Collections.Generic.IEnumerable<OfficeIMO.Email.MapiProperty> required
key OfficeIMO.Email.MapiPropertyKey required

Returns

MapiProperty?
public static MapiProperty? GetMapiProperty(IEnumerable<MapiProperty> properties, ushort propertyId) #

Finds the last standard property with the specified property identifier.

Parameters

properties System.Collections.Generic.IEnumerable<OfficeIMO.Email.MapiProperty> required
propertyId ushort required

Returns

MapiProperty?
public static MapiProperty? GetMapiProperty(IEnumerable<MapiProperty> properties, Guid propertySet, uint localId) #

Finds the last numeric named property with the specified canonical identity.

Parameters

properties System.Collections.Generic.IEnumerable<OfficeIMO.Email.MapiProperty> required
propertySet System.Guid required
localId uint required

Returns

MapiProperty?
public static MapiProperty? GetMapiProperty(IEnumerable<MapiProperty> properties, Guid propertySet, string name) #

Finds the last string named property with the specified canonical identity.

Parameters

properties System.Collections.Generic.IEnumerable<OfficeIMO.Email.MapiProperty> required
propertySet System.Guid required
name string required

Returns

MapiProperty?
public static T? GetMapiValueOrDefault<T>(IEnumerable<MapiProperty> properties, MapiPropertyKey<T?> key) #

Reads a typed property, or the managed default when it is absent or incompatible.

Type Parameters

T

Parameters

properties System.Collections.Generic.IEnumerable<OfficeIMO.Email.MapiProperty> required
key OfficeIMO.Email.MapiPropertyKey<T?> required

Returns

T?
GetMapiValue``1 3 overloads
public static T? GetMapiValue<T>(IEnumerable<MapiProperty> properties, ushort propertyId) #

Gets a typed standard property value, or the default value when it is absent or has another type.

Type Parameters

T

Parameters

properties System.Collections.Generic.IEnumerable<OfficeIMO.Email.MapiProperty> required
propertyId ushort required

Returns

T?
public static T? GetMapiValue<T>(IEnumerable<MapiProperty> properties, Guid propertySet, uint localId) #

Gets a typed numeric named property value, or the default value when it is absent or has another type.

Type Parameters

T

Parameters

properties System.Collections.Generic.IEnumerable<OfficeIMO.Email.MapiProperty> required
propertySet System.Guid required
localId uint required

Returns

T?
public static T? GetMapiValue<T>(IEnumerable<MapiProperty> properties, Guid propertySet, string name) #

Gets a typed string named property value, or the default value when it is absent or has another type.

Type Parameters

T

Parameters

properties System.Collections.Generic.IEnumerable<OfficeIMO.Email.MapiProperty> required
propertySet System.Guid required
name string required

Returns

T?
public static T? GetNullableMapiValue<T>(IEnumerable<MapiProperty> properties, MapiPropertyKey<T> key) #

Reads a value-type property, or null when it is absent or incompatible.

Type Parameters

T

Parameters

properties System.Collections.Generic.IEnumerable<OfficeIMO.Email.MapiProperty> required
key OfficeIMO.Email.MapiPropertyKey<T> required

Returns

T?
public static MapiProperty? GetRawMapiProperty(IEnumerable<MapiProperty> properties, MapiPropertyKey key) #

Finds the last property matching a typed key's identity without checking its wire type.

Parameters

properties System.Collections.Generic.IEnumerable<OfficeIMO.Email.MapiProperty> required
key OfficeIMO.Email.MapiPropertyKey required

Returns

MapiProperty?
public static bool TryGetMapiValue<T>(IEnumerable<MapiProperty> properties, MapiPropertyKey<T?> key, out T? value) #

Attempts to read a property using a typed key.

Type Parameters

T

Parameters

properties System.Collections.Generic.IEnumerable<OfficeIMO.Email.MapiProperty> required
key OfficeIMO.Email.MapiPropertyKey<T?> required
value T? required

Returns

bool