/// <summary> /// Creates a builder with all elements set to the same values as the /// given CacheDirectiveInfo. /// </summary> public Builder(CacheDirectiveInfo directive) { this.id = directive.GetId(); this.path = directive.GetPath(); this.replication = directive.GetReplication(); this.pool = directive.GetPool(); this.expiration = directive.GetExpiration(); }
internal CacheDirectiveInfo(long id, Path path, short replication, string pool, CacheDirectiveInfo.Expiration expiration) { this.id = id; this.path = path; this.replication = replication; this.pool = pool; this.expiration = expiration; }
/// <summary>Sets when the CacheDirective should expire.</summary> /// <remarks> /// Sets when the CacheDirective should expire. A /// <see cref="Expiration"/> /// can specify either an absolute or /// relative expiration time. /// </remarks> /// <param name="expiration">when this CacheDirective should expire</param> /// <returns>This builder, for call chaining</returns> public virtual CacheDirectiveInfo.Builder SetExpiration(CacheDirectiveInfo.Expiration expiration) { this.expiration = expiration; return(this); }