SolvedPrivate

searching with linq

Posted on 2014-02-07
1
58 Views
Last Modified: 2016-02-10
I have the following data.  I need to represent this in code somehow..like a struct, or lookup...dictionary..which ever is the best way...and then be able to find the info with LINQ.  How would I set this up.


<KeyPaths>
            <KeyPath EventType="API" Key="MRC" Path="PRPS/PRP[@KEY='MRC']" />
            <KeyPath EventType="API" Key="ARC" Path="PRPS/PRP[@KEY='ARC']" />
            <KeyPath EventType="API" Key="SCHEDULE_CANCEL"   Path="PRPS/PRP[@KEY='SCHEDULE_CANCEL']" />
            <KeyPath EventType="API" Type="Default" Path="FLDS/FLD[@KEY='{0}']" />
            <KeyPath EventType="DMN" Type="Default" Path="{0}" />
</KeyPaths>
0
Comment
Question by:Robb Hill
1 Comment
 
LVL 21

Accepted Solution

by:
Craig Wagner earned 500 total points
ID: 39842578
public class KeyPath
{
    public string EventType { get; set; }
    public string Key { get; set; }
    public string Type { get; set; }
    public string Path { get; set; }
}

var keyPaths = new List<KeyPath>();

Open in new window

0

Featured Post

MIM Survival Guide for Service Desk Managers

Major incidents can send mastered service desk processes into disorder. Systems and tools produce the data needed to resolve these incidents, but your challenge is getting that information to the right people fast. Check out the Survival Guide and begin bringing order to chaos.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

For those of you who don't follow the news, or just happen to live under rocks, Microsoft Research released a beta SDK (http://www.microsoft.com/en-us/download/details.aspx?id=27876) for the Xbox 360 Kinect. If you don't know what a Kinect is (http:…
Entity Framework is a powerful tool to help you interact with the DataBase but still doesn't help much when we have a Stored Procedure that returns more than one resultset. The solution takes some of out-of-the-box thinking; read on!
This video shows how to quickly and easily add an email signature for all users on Exchange 2016. The resulting signature is applied on a server level by Exchange Online. The email signature template has been downloaded from: www.mail-signatures…
With Secure Portal Encryption, the recipient is sent a link to their email address directing them to the email laundry delivery page. From there, the recipient will be required to enter a user name and password to enter the page. Once the recipient …

809 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question