    

 ## On this page

  

 

 # Class LinkPropertyItemCache

 Last update: 16.07.2025 

Namespace: [VM.Models.Pre.Cache](VM.Models.Pre.Cache.md)  
Assembly: VM.Models.Pre.dll

This class serve cache for Link/Child type properties of given object or type

```csharp
public static class LinkPropertyItemCache

```

#### Inheritance

[object](https://learn.microsoft.com/dotnet/api/system.object) ← [LinkPropertyItemCache](VM.Models.Pre.Cache.LinkPropertyItemCache.md)

#### Extension Methods

[LinkPropertyItemCache.GetLinkProperties(object, LinkPropertyType)](VM.Models.Pre.Cache.LinkPropertyItemCache.md#VM_Models_Pre_Cache_LinkPropertyItemCache_GetLinkProperties_System_Object_VM_Models_Pre_LinkPropertyType_), [LinkPropertyItemCache.GetLinkPropertiesAndValues(object, LinkPropertyType)](VM.Models.Pre.Cache.LinkPropertyItemCache.md#VM_Models_Pre_Cache_LinkPropertyItemCache_GetLinkPropertiesAndValues_System_Object_VM_Models_Pre_LinkPropertyType_), [LinkPropertyItemCache.GetLinkedObjects&lt;T&gt;(object, LinkPropertyType)](VM.Models.Pre.Cache.LinkPropertyItemCache.md#VM_Models_Pre_Cache_LinkPropertyItemCache_GetLinkedObjects__1_System_Object_VM_Models_Pre_LinkPropertyType_)

## Methods

### GetLinkProperties(Type, LinkPropertyType)

Get all properties which have LinkAttribute custome attribute for given Type.

```csharp
public static IEnumerable<PropertyInfo> GetLinkProperties(this Type type, LinkPropertyType propertyType = LinkPropertyType.All)

```

#### Parameters

`type` [Type](https://learn.microsoft.com/dotnet/api/system.type)

The  whiche want to find properties.

`propertyType` [LinkPropertyType](VM.Models.Pre.LinkPropertyType.md)

The  to search.

#### Returns

[IEnumerable](https://learn.microsoft.com/dotnet/api/system.collections.generic.ienumerable-1)&lt;[PropertyInfo](https://learn.microsoft.com/dotnet/api/system.reflection.propertyinfo)&gt;

Found  of .

### GetLinkProperties(object, LinkPropertyType)

Get all properties which have LinkAttribute custome attribute for given object.

```csharp
public static IEnumerable<PropertyInfo> GetLinkProperties(this object obj, LinkPropertyType propertyType = LinkPropertyType.All)

```

#### Parameters

`obj` [object](https://learn.microsoft.com/dotnet/api/system.object)

The object whiche want to find properties.

`propertyType` [LinkPropertyType](VM.Models.Pre.LinkPropertyType.md)

The  to search.

#### Returns

[IEnumerable](https://learn.microsoft.com/dotnet/api/system.collections.generic.ienumerable-1)&lt;[PropertyInfo](https://learn.microsoft.com/dotnet/api/system.reflection.propertyinfo)&gt;

Found  of .

### GetLinkPropertiesAndValues(object, LinkPropertyType)

Get all properties and their values which have LinkAttribute custome attribute for given object.

```csharp
public static IEnumerable<(PropertyInfo property, object value)> GetLinkPropertiesAndValues(this object obj, LinkPropertyType propertyType = LinkPropertyType.All)

```

#### Parameters

`obj` [object](https://learn.microsoft.com/dotnet/api/system.object)

The object whiche want to find properties.

`propertyType` [LinkPropertyType](VM.Models.Pre.LinkPropertyType.md)

The  to search.

#### Returns

[IEnumerable](https://learn.microsoft.com/dotnet/api/system.collections.generic.ienumerable-1)&lt;([PropertyInfo](https://learn.microsoft.com/dotnet/api/system.reflection.propertyinfo) [property](https://learn.microsoft.com/dotnet/api/system.valuetuple-system.reflection.propertyinfo,system.object-.property), [object](https://learn.microsoft.com/dotnet/api/system.object) [value](https://learn.microsoft.com/dotnet/api/system.valuetuple-system.reflection.propertyinfo,system.object-.value))&gt;

Found  of  and its value.

### GetLinkedObjects&lt;T&gt;(object, LinkPropertyType)

Get all propertiy values which have LinkAttribute custome attribute for given object.

```csharp
public static IEnumerable<T> GetLinkedObjects<T>(this object obj, LinkPropertyType propertyType = LinkPropertyType.All)

```

#### Parameters

`obj` [object](https://learn.microsoft.com/dotnet/api/system.object)

The object whiche want to find properties.

`propertyType` [LinkPropertyType](VM.Models.Pre.LinkPropertyType.md)

The  to search.

#### Returns

[IEnumerable](https://learn.microsoft.com/dotnet/api/system.collections.generic.ienumerable-1)&lt;T&gt;

Found  of property values.

#### Type Parameters

`T`

The type of property value