xrootd
Loading...
Searching...
No Matches
Public Attributes | List of all members
XrdOucPgrwUtils::Layout Struct Reference

Compute the layout for an iovec that receives network bytes applying. More...

#include <XrdOucPgrwUtils.hh>

Public Attributes

off_t bOffset
 Buffer offset to apply iov[1].iov_base.
 
int dataLen
 Total number of filesys bytes the iovec will handle.
 
int sockLen
 Total number of network bytes the iovec will handle.
 
int fLen
 Length to use for iov[1].iov_len.
 
int lLen
 Length to use for iov[csnum*2-1].iov_len)
 
const char * eWhy
 Reason for failure when zero is returned.
 

Detailed Description

Compute the layout for an iovec that receives network bytes applying.

Parameters
layoutReference to the layout parameter (see below).
offsrecvLayout: Offset at which the subsequent write occurs. sendLayout: Offset at which the preceding read occurs.
dlenrecvLayout: Nmber of sock bytes to receive with checksums.
dlensendLayout: Nmber of file bytes to read without checksums.
bszThe size of the buffer exclusive of any checksums and must be a multiple of 4096 (one page). If it's <= 0 then then the layout is computed as if bsz could fully accomodate the dlen.
Returns
The number of checksums that are needed. If the result is zero then the supplied offset/dlen violates requirements amd eWhy holds reason.
Note
The iovec layout assumes iov[0] reads the checksum and iov[1] reads only the data where the last such pair is iov[csnum*-2],iov[csnum*-1].
dataLen can be used to adjust the next offset for filesystem I/O while sockLen is the total number of network bytes to receive or send.

Member Data Documentation

◆ bOffset

off_t XrdOucPgrwUtils::Layout::bOffset

Buffer offset to apply iov[1].iov_base.

◆ dataLen

int XrdOucPgrwUtils::Layout::dataLen

Total number of filesys bytes the iovec will handle.

◆ eWhy

const char* XrdOucPgrwUtils::Layout::eWhy

Reason for failure when zero is returned.

◆ fLen

int XrdOucPgrwUtils::Layout::fLen

Length to use for iov[1].iov_len.

◆ lLen

int XrdOucPgrwUtils::Layout::lLen

Length to use for iov[csnum*2-1].iov_len)

◆ sockLen

int XrdOucPgrwUtils::Layout::sockLen

Total number of network bytes the iovec will handle.


The documentation for this struct was generated from the following file: