コード例 #1
0
ファイル: USE_Data.cs プロジェクト: zachsimop/USE-Tutorial
 public Datum(string nm, Func <T> variable)
 {
     name = nm;
     //most variables can use standard tostring method - if not will have to add if statements to build custom string methods
     {
         stringFunc = () => variable().ToString();//toString(()=>variable());
     }
 }
コード例 #2
0
ファイル: delegate.cs プロジェクト: earsie/C-Sharp
    public static void Main()
    {
        stringFunction del = new stringFunction(Hey);

        del("Hey there!"); //this is the value that is delegated to the Hey var
    }
コード例 #3
0
ファイル: TextInput.cs プロジェクト: cashilts/GameJamS2017
 public void setCallback(stringFunction newCallback)
 {
     callback = newCallback;
 }
コード例 #4
0
ファイル: delegate.cs プロジェクト: earsie/C-Sharp
 public static void Main()
 {
     stringFunction del = new stringFunction(Hey);
     del("Hey there!"); //this is the value that is delegated to the Hey var
 }