Find usage of property from base entity

前端 未结 1 1446
旧巷少年郎
旧巷少年郎 2021-01-06 08:03

I\'m trying to find the usage of a property in a class where the property belongs to a base class. Here is a token example:

class Program
{
    class Item
           


        
相关标签:
1条回答
  • 2021-01-06 08:32

    For this case is very usefull the ReSharper's SRP (Search and Replace with Pattern).

    Menu Resharper->Find->Search with Pattern...

    define here following pattern:

    $Item$.Price
    

    of for write usages only:

    $Item$.Price = $exp$;
    

    or for read usages only:

    $exp$ = $Item$.Price
    

    where $Item$ should be an expression placeholder, select the type "Bicycle" and don't forget to check "Exactly this type".

    The $exp$ can stay undefined

    0 讨论(0)
提交回复
热议问题