fetch options.

interface Options {
    acceptContentType?: readonly number[];
    cOpts?: ConsumerOptions;
    ca?: CongestionAvoidance;
    describe?: string;
    endpoint?: Endpoint;
    estimatedFinalSegNum?: number;
    fw?: Forwarder;
    lifetimeAfterRto?: number;
    modifyInterest?: Modify;
    retxLimit?: number;
    rtte?: RttEstimator | Partial<Parameters>;
    segmentNumConvention?: SegmentConvention;
    segmentRange?: [number, undefined | number];
    signal?: AbortSignal;
    verifier?: Verifier;
}

Hierarchy

  • Options
    • Options

    Properties

    acceptContentType?: readonly number[]

    List of acceptable ContentType values.

    Default Value

    [0]

    Inherit fetcher options from consumer options.

    Remarks

    These options are inherited if the corresponding fetcher option is unset:

    • describe
    • fw
    • modifyInterest
    • signal
    • verifier

    Other options cannot be inherited, notably:

    • retx

    Use given congestion avoidance instance.

    describe?: string

    FwFace description.

    Default Value

    "fetch" + name
    
    endpoint?: Endpoint

    Inherit fetcher options from Endpoint consumer options.

    Deprecated

    Specify .cOpts.

    estimatedFinalSegNum?: number

    Estimated final segment number (inclusive).

    Remarks

    If specified, FetchLogic sends Interests up to this segment number initially as permitted by congestion control, then sends further Interests in a stop-and-wait manner, unless a new estimation or known finalSegNum is provided via setFinalSegNum() function.

    Use the specified logical forwarder.

    Default Value

    Forwarder.getDefault()

    lifetimeAfterRto?: number

    InterestLifetime added to RTO.

    Default Value

    1000ms
    
    modifyInterest?: Modify

    Modify Interest according to specified options.

    Remarks

    This can also be used to witness Interests without modification.

    retxLimit?: number

    Maximum number of retransmissions, excluding initial Interest.

    Default Value

    15
    
    rtte?: RttEstimator | Partial<Parameters>

    Use given RttEstimator instance or construct RttEstimator from options.

    segmentNumConvention?: SegmentConvention

    Choose a segment number naming convention.

    Default Value

    Segment3

    segmentRange?: [number, undefined | number]

    Specify segment number range as [begin, end).

    Remarks

    The begin segment number is inclusive and the end segment number is exclusive. If the begin segment number is greater than the final segment number, fetching will fail. If the end segment number is undefined or greater than the final segment number, fetching will stop at the final segment.

    signal?: AbortSignal

    AbortSignal that allows canceling the Interest via AbortController.

    verifier?: Verifier

    Data verifier.

    Default Value

    No verification.