Solved

Explain the bolded code

Posted on 2011-09-09
2
232 Views
Last Modified: 2012-05-12
namespace CommaValues
{
    class Program
    {
[b]        private static List<Dictionary<string, string>> GetData(
   out List<string> columns)[/b]
        {

Open in new window


Can someone clarify exactly what the bolded code does?
0
Comment
Question by:vincentvanhst
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 75

Accepted Solution

by:
käµfm³d   👽 earned 500 total points
ID: 36511506
The function GetData returns a List of Dictionaries, where the key and value of each Dictionary are of type string. This function also has an out parameter, which also acts kind of like a return value--it's a parameter returned by reference. An out parameter can be either unitilialized or initialized before being passed to the function, but it is expected to be assigned to before the function returns. There is also the ref keyword which functions similarly to out, except that the parameter is expected to be initialized prior to passed to the function.
0
 

Author Closing Comment

by:vincentvanhst
ID: 36513426
Thanks buddy, I understand now with your detailed description :)
0

Featured Post

Revamp Your Training Process

Drastically shorten your training time with WalkMe's advanced online training solution that Guides your trainees to action.

Question has a verified solution.

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

Suggested Solutions

This article describes a simple method to resize a control at runtime.  It includes ready-to-use source code and a complete sample demonstration application.  We'll also talk about C# Extension Methods. Introduction In one of my applications…
The article shows the basic steps of integrating an HTML theme template into an ASP.NET MVC project
I've attached the XLSM Excel spreadsheet I used in the video and also text files containing the macros used below. https://filedb.experts-exchange.com/incoming/2017/03_w12/1151775/Permutations.txt https://filedb.experts-exchange.com/incoming/201…
How to Install VMware Tools in Red Hat Enterprise Linux 6.4 (RHEL 6.4) Step-by-Step Tutorial

734 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