I can’t find out how to use the Logger in my own classes. Right now, i setup a test class that just does that:
- region usings (just copied these over from project's myNode.cs file)
using System;
using System.Collections.Generic;
using System.Runtime.Serialization;
using System.Linq;
using System.Text;
using VVVV.Utils.VColor;
using VVVV.Utils;
using VVVV.Nodes;
using VVVV.Core.Logging;
- endregion usings
class LogTest {
public ILogger FLogger;
public void doSome(string s){
FLogger.Log(LogType.Debug,s);
}
}
which is in a separate file i added via the project manager.
It’s object lt is called from myNode’s Evaluate() like:
LogTest lt = new LogTest();
lt.doSome("HELLO");
Which would not appear in the TTY.
Of course, the FLogger in the declaration is underlined in yellow because it is never assigned anything. I tried deriving the Logger as a Constructor argument for subclasses, resulting in a red node (and ugly code).
Any hints where i’m wrong?