Exemplo n.º 1
0
 public @event(@string WhenString = default, time.Duration Elapsed = default, ulong Go = default, @string What = default)
 {
     this.WhenString = WhenString;
     this.Elapsed    = Elapsed;
     this.Go         = Go;
     this.What       = What;
 }
 public maxLatencyWriter(writeFlusher dst = default, time.Duration latency = default, sync.Mutex mu = default, ref ptr <time.Timer> t = default, bool flushPending = default)
 {
     this.dst          = dst;
     this.latency      = latency;
     this.mu           = mu;
     this.t            = t;
     this.flushPending = flushPending;
 }
Exemplo n.º 3
0
 public BenchmarkResult(long N = default, time.Duration T = default, long Bytes = default, ulong MemAllocs = default, ulong MemBytes = default, map <@string, double> Extra = default)
 {
     this.N         = N;
     this.T         = T;
     this.Bytes     = Bytes;
     this.MemAllocs = MemAllocs;
     this.MemBytes  = MemBytes;
     this.Extra     = Extra;
 }
Exemplo n.º 4
0
 public Dialer(time.Duration Timeout = default, time.Time Deadline = default, Addr LocalAddr = default, bool DualStack = default, time.Duration FallbackDelay = default, time.Duration KeepAlive = default, ref ptr <Resolver> Resolver = default, channel <object> Cancel = default, Func <@string, @string, syscall.RawConn, error> Control = default)
 {
     this.Timeout       = Timeout;
     this.Deadline      = Deadline;
     this.LocalAddr     = LocalAddr;
     this.DualStack     = DualStack;
     this.FallbackDelay = FallbackDelay;
     this.KeepAlive     = KeepAlive;
     this.Resolver      = Resolver;
     this.Cancel        = Cancel;
     this.Control       = Control;
 }
Exemplo n.º 5
0
            // timeZone returns a *time.Location based on the provided offset.
            // If the offset is non-sensible, then this uses an offset of zero.
            private static ref time.Location timeZone(time.Duration offset)
            {
                const long minOffset   = -12L * time.Hour;  // E.g., Baker island at -12:00
                const long maxOffset   = +14L * time.Hour;  // E.g., Line island at +14:00
                const long offsetAlias = 15L * time.Minute; // E.g., Nepal at +5:45

                offset = offset.Round(offsetAlias);
                if (offset < minOffset || maxOffset < offset)
                {
                    offset = 0L;
                }
                return(time.FixedZone("", int(offset / time.Second)));
            }
Exemplo n.º 6
0
 public timeoutHandler(Handler handler = default, @string body = default, time.Duration dt = default, context.Context testContext = default)
 {
     this.handler     = handler;
     this.body        = body;
     this.dt          = dt;
     this.testContext = testContext;
 }
Exemplo n.º 7
0
 public action(sync.Once once = default, ref ptr <analysis.Analyzer> a = default, ref ptr <packages.Package> pkg = default, ref ptr <analysis.Pass> pass = default, bool isroot = default, slice <ptr <action> > deps = default, map <objectFactKey, analysis.Fact> objectFacts = default, map <packageFactKey, analysis.Fact> packageFacts = default, slice <analysis.Diagnostic> diagnostics = default, error err = default, time.Duration duration = default)
 {
     this.once         = once;
     this.a            = a;
     this.pkg          = pkg;
     this.pass         = pass;
     this.isroot       = isroot;
     this.deps         = deps;
     this.objectFacts  = objectFacts;
     this.packageFacts = packageFacts;
     this.diagnostics  = diagnostics;
     this.err          = err;
     this.duration     = duration;
 }
Exemplo n.º 8
0
 public BenchmarkResult(long N = default, time.Duration T = default, long Bytes = default)
 {
     this.N     = N;
     this.T     = T;
     this.Bytes = Bytes;
 }
 public http2ClientConn(ref ptr<http2Transport> t = default, net.Conn tconn = default, ref ptr<tls.ConnectionState> tlsState = default, uint reused = default, bool singleUse = default, channel<object> readerDone = default, error readerErr = default, time.Duration idleTimeout = default, ref ptr<time.Timer> idleTimer = default, sync.Mutex mu = default, ref ptr<sync.Cond> cond = default, http2flow flow = default, http2flow inflow = default, bool closing = default, bool closed = default, bool wantSettingsAck = default, ref ptr<http2GoAwayFrame> goAway = default, @string goAwayDebug = default, map<uint, ptr<http2clientStream>> streams = default, uint nextStreamID = default, long pendingRequests = default, map<array<byte>, channel<object>> pings = default, ref ptr<bufio.Writer> bw = default, ref ptr<bufio.Reader> br = default, ref ptr<http2Framer> fr = default, time.Time lastActive = default, time.Time lastIdle = default, uint maxFrameSize = default, uint maxConcurrentStreams = default, ulong peerMaxHeaderListSize = default, uint initialWindowSize = default, bytes.Buffer hbuf = default, ref ptr<hpack.Encoder> henc = default, slice<slice<byte>> freeBuf = default, sync.Mutex wmu = default, error werr = default)
 {
     this.t = t;
     this.tconn = tconn;
     this.tlsState = tlsState;
     this.reused = reused;
     this.singleUse = singleUse;
     this.readerDone = readerDone;
     this.readerErr = readerErr;
     this.idleTimeout = idleTimeout;
     this.idleTimer = idleTimer;
     this.mu = mu;
     this.cond = cond;
     this.flow = flow;
     this.inflow = inflow;
     this.closing = closing;
     this.closed = closed;
     this.wantSettingsAck = wantSettingsAck;
     this.goAway = goAway;
     this.goAwayDebug = goAwayDebug;
     this.streams = streams;
     this.nextStreamID = nextStreamID;
     this.pendingRequests = pendingRequests;
     this.pings = pings;
     this.bw = bw;
     this.br = br;
     this.fr = fr;
     this.lastActive = lastActive;
     this.lastIdle = lastIdle;
     this.maxFrameSize = maxFrameSize;
     this.maxConcurrentStreams = maxConcurrentStreams;
     this.peerMaxHeaderListSize = peerMaxHeaderListSize;
     this.initialWindowSize = initialWindowSize;
     this.hbuf = hbuf;
     this.henc = henc;
     this.freeBuf = freeBuf;
     this.wmu = wmu;
     this.werr = werr;
 }
Exemplo n.º 10
0
 public dnsConfig(slice <@string> servers = default, slice <@string> search = default, long ndots = default, time.Duration timeout = default, long attempts = default, bool rotate = default, bool unknownOpt = default, slice <@string> lookup = default, error err = default, time.Time mtime = default, uint soffset = default, bool singleRequest = default, bool useTCP = default)
 {
     this.servers       = servers;
     this.search        = search;
     this.ndots         = ndots;
     this.timeout       = timeout;
     this.attempts      = attempts;
     this.rotate        = rotate;
     this.unknownOpt    = unknownOpt;
     this.lookup        = lookup;
     this.err           = err;
     this.mtime         = mtime;
     this.soffset       = soffset;
     this.singleRequest = singleRequest;
     this.useTCP        = useTCP;
 }
Exemplo n.º 11
0
 public DB(long waitDuration = default, driver.Connector connector = default, ulong numClosed = default, sync.Mutex mu = default, slice <ptr <driverConn> > freeConn = default, map <ulong, channel <connRequest> > connRequests = default, ulong nextRequest = default, long numOpen = default, channel <object> openerCh = default, bool closed = default, map <finalCloser, depSet> dep = default, map <ptr <driverConn>, @string> lastPut = default, long maxIdleCount = default, long maxOpen = default, time.Duration maxLifetime = default, time.Duration maxIdleTime = default, channel <object> cleanerCh = default, long waitCount = default, long maxIdleClosed = default, long maxIdleTimeClosed = default, long maxLifetimeClosed = default, Action stop = default)
 {
     this.waitDuration      = waitDuration;
     this.connector         = connector;
     this.numClosed         = numClosed;
     this.mu                = mu;
     this.freeConn          = freeConn;
     this.connRequests      = connRequests;
     this.nextRequest       = nextRequest;
     this.numOpen           = numOpen;
     this.openerCh          = openerCh;
     this.closed            = closed;
     this.dep               = dep;
     this.lastPut           = lastPut;
     this.maxIdleCount      = maxIdleCount;
     this.maxOpen           = maxOpen;
     this.maxLifetime       = maxLifetime;
     this.maxIdleTime       = maxIdleTime;
     this.cleanerCh         = cleanerCh;
     this.waitCount         = waitCount;
     this.maxIdleClosed     = maxIdleClosed;
     this.maxIdleTimeClosed = maxIdleTimeClosed;
     this.maxLifetimeClosed = maxLifetimeClosed;
     this.stop              = stop;
 }
Exemplo n.º 12
0
 public common(sync.RWMutex mu = default, slice<byte> output = default, io.Writer w = default, bool ran = default, bool failed = default, bool skipped = default, bool done = default, Action cleanup = default, @string cleanupName = default, slice<System.UIntPtr> cleanupPc = default, bool chatty = default, bool bench = default, bool finished = default, int hasSub = default, long raceErrors = default, @string runner = default, ref ptr<common> parent = default, long level = default, slice<System.UIntPtr> creator = default, @string name = default, time.Time start = default, time.Duration duration = default, channel<bool> barrier = default, channel<bool> signal = default, slice<ptr<T>> sub = default, sync.Once tempDirOnce = default, @string tempDir = default, error tempDirErr = default, int tempDirSeq = default)
 {
     this.mu = mu;
     this.output = output;
     this.w = w;
     this.ran = ran;
     this.failed = failed;
     this.skipped = skipped;
     this.done = done;
     this.cleanup = cleanup;
     this.cleanupName = cleanupName;
     this.cleanupPc = cleanupPc;
     this.chatty = chatty;
     this.bench = bench;
     this.finished = finished;
     this.hasSub = hasSub;
     this.raceErrors = raceErrors;
     this.runner = runner;
     this.parent = parent;
     this.level = level;
     this.creator = creator;
     this.name = name;
     this.start = start;
     this.duration = duration;
     this.barrier = barrier;
     this.signal = signal;
     this.sub = sub;
     this.tempDirOnce = tempDirOnce;
     this.tempDir = tempDir;
     this.tempDirErr = tempDirErr;
     this.tempDirSeq = tempDirSeq;
 }
Exemplo n.º 13
0
 public Server(@string Addr = default, Handler Handler = default, ref ptr <tls.Config> TLSConfig = default, time.Duration ReadTimeout = default, time.Duration ReadHeaderTimeout = default, time.Duration WriteTimeout = default, time.Duration IdleTimeout = default, long MaxHeaderBytes = default, map <@string, Action <ptr <Server>, ptr <tls.Conn>, Handler> > TLSNextProto = default, Action <net.Conn, ConnState> ConnState = default, ref ptr <log.Logger> ErrorLog = default, Func <net.Listener, context.Context> BaseContext = default, Func <context.Context, net.Conn, context.Context> ConnContext = default, atomicBool inShutdown = default, int disableKeepAlives = default, sync.Once nextProtoOnce = default, error nextProtoErr = default, sync.Mutex mu = default, channel <object> doneChan = default, slice <Action> onShutdown = default)
 {
     this.Addr              = Addr;
     this.Handler           = Handler;
     this.TLSConfig         = TLSConfig;
     this.ReadTimeout       = ReadTimeout;
     this.ReadHeaderTimeout = ReadHeaderTimeout;
     this.WriteTimeout      = WriteTimeout;
     this.IdleTimeout       = IdleTimeout;
     this.MaxHeaderBytes    = MaxHeaderBytes;
     this.TLSNextProto      = TLSNextProto;
     this.ConnState         = ConnState;
     this.ErrorLog          = ErrorLog;
     this.BaseContext       = BaseContext;
     this.ConnContext       = ConnContext;
     this.inShutdown        = inShutdown;
     this.disableKeepAlives = disableKeepAlives;
     this.nextProtoOnce     = nextProtoOnce;
     this.nextProtoErr      = nextProtoErr;
     this.mu         = mu;
     this.doneChan   = doneChan;
     this.onShutdown = onShutdown;
 }
Exemplo n.º 14
0
 public Client(RoundTripper Transport = default, Func <ptr <Request>, slice <ptr <Request> >, error> CheckRedirect = default, CookieJar Jar = default, time.Duration Timeout = default)
 {
     this.Transport     = Transport;
     this.CheckRedirect = CheckRedirect;
     this.Jar           = Jar;
     this.Timeout       = Timeout;
 }
Exemplo n.º 15
0
 public benchTimeFlag(time.Duration d = default, long n = default)
 {
     this.d = d;
     this.n = n;
 }
Exemplo n.º 16
0
 public B(common common = default, @string importPath = default, ref ptr <benchContext> context = default, long N = default, long previousN = default, time.Duration previousDuration = default, Action <ptr <B> > benchFunc = default, benchTimeFlag benchTime = default, long bytes = default, bool missingBytes = default, bool timerOn = default, bool showAllocResult = default, BenchmarkResult result = default, long parallelism = default, ulong startAllocs = default, ulong startBytes = default, ulong netAllocs = default, ulong netBytes = default, map <@string, double> extra = default)
 {
     this.common           = common;
     this.importPath       = importPath;
     this.context          = context;
     this.N                = N;
     this.previousN        = previousN;
     this.previousDuration = previousDuration;
     this.benchFunc        = benchFunc;
     this.benchTime        = benchTime;
     this.bytes            = bytes;
     this.missingBytes     = missingBytes;
     this.timerOn          = timerOn;
     this.showAllocResult  = showAllocResult;
     this.result           = result;
     this.parallelism      = parallelism;
     this.startAllocs      = startAllocs;
     this.startBytes       = startBytes;
     this.netAllocs        = netAllocs;
     this.netBytes         = netBytes;
     this.extra            = extra;
 }
Exemplo n.º 17
0
 public http2Server(long MaxHandlers = default, uint MaxConcurrentStreams = default, uint MaxReadFrameSize = default, bool PermitProhibitedCipherSuites = default, time.Duration IdleTimeout = default, int MaxUploadBufferPerConnection = default, int MaxUploadBufferPerStream = default, Func <http2WriteScheduler> NewWriteScheduler = default, ref ptr <http2serverInternalState> state = default)
 {
     this.MaxHandlers                  = MaxHandlers;
     this.MaxConcurrentStreams         = MaxConcurrentStreams;
     this.MaxReadFrameSize             = MaxReadFrameSize;
     this.PermitProhibitedCipherSuites = PermitProhibitedCipherSuites;
     this.IdleTimeout                  = IdleTimeout;
     this.MaxUploadBufferPerConnection = MaxUploadBufferPerConnection;
     this.MaxUploadBufferPerStream     = MaxUploadBufferPerStream;
     this.NewWriteScheduler            = NewWriteScheduler;
     this.state = state;
 }
Exemplo n.º 18
0
 public entry(@string WhenString = default, ulong ID = default, time.Duration Duration = default, bool Complete = default, slice <event> Events = default, time.Duration Start = default, time.Duration End = default, time.Duration GCTime = default)
 public http2bodyWriterState(ref ptr <http2clientStream> cs = default, ref ptr <time.Timer> timer = default, ref ptr <sync.Once> fnonce = default, Action fn = default, channel <error> resc = default, time.Duration delay = default)
 {
     this.cs     = cs;
     this.timer  = timer;
     this.fnonce = fnonce;
     this.fn     = fn;
     this.resc   = resc;
     this.delay  = delay;
 }
Exemplo n.º 20
0
 public actionJSON(long ID = default, @string Mode = default, @string Package = default, slice <long> Deps = default, bool IgnoreFail = default, slice <@string> Args = default, bool Link = default, @string Objdir = default, @string Target = default, long Priority = default, bool Failed = default, @string Built = default, bool VetxOnly = default, bool NeedVet = default, bool NeedBuild = default, @string ActionID = default, @string BuildID = default, time.Time TimeReady = default, time.Time TimeStart = default, time.Time TimeDone = default, slice <@string> Cmd = default, time.Duration CmdReal = default, time.Duration CmdUser = default, time.Duration CmdSys = default)
 {
     this.ID         = ID;
     this.Mode       = Mode;
     this.Package    = Package;
     this.Deps       = Deps;
     this.IgnoreFail = IgnoreFail;
     this.Args       = Args;
     this.Link       = Link;
     this.Objdir     = Objdir;
     this.Target     = Target;
     this.Priority   = Priority;
     this.Failed     = Failed;
     this.Built      = Built;
     this.VetxOnly   = VetxOnly;
     this.NeedVet    = NeedVet;
     this.NeedBuild  = NeedBuild;
     this.ActionID   = ActionID;
     this.BuildID    = BuildID;
     this.TimeReady  = TimeReady;
     this.TimeStart  = TimeStart;
     this.TimeDone   = TimeDone;
     this.Cmd        = Cmd;
     this.CmdReal    = CmdReal;
     this.CmdUser    = CmdUser;
     this.CmdSys     = CmdSys;
 }
Exemplo n.º 21
0
 private static error setKeepAlivePeriod(ptr <netFD> _addr_fd, time.Duration d)
 {
     ref netFD fd = ref _addr_fd.val;
Exemplo n.º 22
0
 public GotConnInfo(net.Conn Conn = default, bool Reused = default, bool WasIdle = default, time.Duration IdleTime = default)
 {
     this.Conn     = Conn;
     this.Reused   = Reused;
     this.WasIdle  = WasIdle;
     this.IdleTime = IdleTime;
 }
Exemplo n.º 23
0
 public common(slice <byte> output = default, bool failed = default, time.Time start = default, time.Duration duration = default, channel <object> signal = default)
 {
     this.output   = output;
     this.failed   = failed;
     this.start    = start;
     this.duration = duration;
     this.signal   = signal;
 }
Exemplo n.º 24
0
 public DBStats(long MaxOpenConnections = default, long OpenConnections = default, long InUse = default, long Idle = default, long WaitCount = default, time.Duration WaitDuration = default, long MaxIdleClosed = default, long MaxIdleTimeClosed = default, long MaxLifetimeClosed = default)
 {
     this.MaxOpenConnections = MaxOpenConnections;
     this.OpenConnections    = OpenConnections;
     this.InUse             = InUse;
     this.Idle              = Idle;
     this.WaitCount         = WaitCount;
     this.WaitDuration      = WaitDuration;
     this.MaxIdleClosed     = MaxIdleClosed;
     this.MaxIdleTimeClosed = MaxIdleTimeClosed;
     this.MaxLifetimeClosed = MaxLifetimeClosed;
 }
Exemplo n.º 25
0
Arquivo: pprof.cs Projeto: zjmit/go2cs
 private static (ptr <profile.Profile>, @string, error) Fetch(this ptr <fetcher> _addr_f, @string src, time.Duration duration, time.Duration timeout)
 {
     ptr <profile.Profile> _p0 = default !;
Exemplo n.º 26
0
 public Config(time.Time Start = default, @string Host = default, uint Process = default, ref ptr <http.Client> Client = default, @string Service = default, @string Address = default, time.Duration Rate = default)
 {
     this.Start   = Start;
     this.Host    = Host;
     this.Process = Process;
     this.Client  = Client;
     this.Service = Service;
     this.Address = Address;
     this.Rate    = Rate;
 }
Exemplo n.º 27
0
 public ListenConfig(Func <@string, @string, syscall.RawConn, error> Control = default, time.Duration KeepAlive = default)
 {
     this.Control   = Control;
     this.KeepAlive = KeepAlive;
 }
 public ReverseProxy(Action <ptr <http.Request> > Director = default, http.RoundTripper Transport = default, time.Duration FlushInterval = default, ref ptr <log.Logger> ErrorLog = default, BufferPool BufferPool = default, Func <ptr <http.Response>, error> ModifyResponse = default, Action <http.ResponseWriter, ptr <http.Request>, error> ErrorHandler = default)
 {
     this.Director       = Director;
     this.Transport      = Transport;
     this.FlushInterval  = FlushInterval;
     this.ErrorLog       = ErrorLog;
     this.BufferPool     = BufferPool;
     this.ModifyResponse = ModifyResponse;
     this.ErrorHandler   = ErrorHandler;
 }