Motr  M0
Extent

Data Structures

struct  m0_ext
 

Macros

#define M0_EXT(start, end)   ((struct m0_ext){ .e_start = (start), .e_end = (end) })
 
#define EXT_F   "[%" PRIx64 ", %" PRIx64 ")"
 
#define EXT_P(x)   (x)->e_start, (x)->e_end
 

Enumerations

enum  m0_ext_format_version { M0_EXT_FORMAT_VERSION_1 = 1, M0_EXT_FORMAT_VERSION = M0_EXT_FORMAT_VERSION_1 }
 

Functions

M0_INTERNAL void m0_ext_init (struct m0_ext *ext)
 
M0_INTERNAL m0_bcount_t m0_ext_length (const struct m0_ext *ext)
 
M0_INTERNAL bool m0_ext_is_in (const struct m0_ext *ext, m0_bindex_t index)
 
M0_INTERNAL bool m0_ext_are_overlapping (const struct m0_ext *e0, const struct m0_ext *e1)
 
M0_INTERNAL bool m0_ext_is_partof (const struct m0_ext *super, const struct m0_ext *sub)
 
M0_INTERNAL bool m0_ext_equal (const struct m0_ext *a, const struct m0_ext *b)
 
M0_INTERNAL bool m0_ext_is_empty (const struct m0_ext *ext)
 
M0_INTERNAL void m0_ext_intersection (const struct m0_ext *e0, const struct m0_ext *e1, struct m0_ext *result)
 
M0_INTERNAL bool m0_ext_is_valid (const struct m0_ext *ext)
 
struct m0_ext M0_XCA_DOMAIN (be|rpc)
 
M0_INTERNAL void m0_ext_sub (const struct m0_ext *minuend, const struct m0_ext *subtrahend, struct m0_ext *difference)
 
M0_INTERNAL void m0_ext_add (const struct m0_ext *term0, const struct m0_ext *term1, struct m0_ext *sum)
 
M0_INTERNAL m0_bindex_t m0_ext_cap (const struct m0_ext *ext2, m0_bindex_t val)
 

Variables

enum m0_ext_format_version M0_XCA_DOMAIN
 

Detailed Description

Macro Definition Documentation

◆ EXT_F

#define EXT_F   "[%" PRIx64 ", %" PRIx64 ")"

Definition at line 85 of file ext.h.

◆ EXT_P

#define EXT_P (   x)    (x)->e_start, (x)->e_end

Definition at line 86 of file ext.h.

◆ M0_EXT

#define M0_EXT (   start,
  end 
)    ((struct m0_ext){ .e_start = (start), .e_end = (end) })

Definition at line 55 of file ext.h.

Enumeration Type Documentation

◆ m0_ext_format_version

Enumerator
M0_EXT_FORMAT_VERSION_1 
M0_EXT_FORMAT_VERSION 

Current version, should point to the latest version present

Definition at line 44 of file ext.h.

Function Documentation

◆ m0_ext_add()

M0_INTERNAL void m0_ext_add ( const struct m0_ext term0,
const struct m0_ext term1,
struct m0_ext sum 
)

◆ m0_ext_are_overlapping()

M0_INTERNAL bool m0_ext_are_overlapping ( const struct m0_ext e0,
const struct m0_ext e1 
)

Definition at line 53 of file ext.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ m0_ext_cap()

M0_INTERNAL m0_bindex_t m0_ext_cap ( const struct m0_ext ext2,
m0_bindex_t  val 
)

◆ m0_ext_equal()

M0_INTERNAL bool m0_ext_equal ( const struct m0_ext a,
const struct m0_ext b 
)

Definition at line 70 of file ext.c.

Here is the caller graph for this function:

◆ m0_ext_init()

M0_INTERNAL void m0_ext_init ( struct m0_ext ext)

Definition at line 32 of file ext.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ m0_ext_intersection()

M0_INTERNAL void m0_ext_intersection ( const struct m0_ext e0,
const struct m0_ext e1,
struct m0_ext result 
)

Definition at line 81 of file ext.c.

Here is the caller graph for this function:

◆ m0_ext_is_empty()

M0_INTERNAL bool m0_ext_is_empty ( const struct m0_ext ext)

Definition at line 76 of file ext.c.

Here is the caller graph for this function:

◆ m0_ext_is_in()

M0_INTERNAL bool m0_ext_is_in ( const struct m0_ext ext,
m0_bindex_t  index 
)

Definition at line 48 of file ext.c.

Here is the caller graph for this function:

◆ m0_ext_is_partof()

M0_INTERNAL bool m0_ext_is_partof ( const struct m0_ext super,
const struct m0_ext sub 
)

Definition at line 62 of file ext.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ m0_ext_is_valid()

M0_INTERNAL bool m0_ext_is_valid ( const struct m0_ext ext)

Tells if start of extent is less than end of extent.

Definition at line 90 of file ext.c.

Here is the caller graph for this function:

◆ m0_ext_length()

M0_INTERNAL m0_bcount_t m0_ext_length ( const struct m0_ext ext)

Definition at line 42 of file ext.c.

Here is the caller graph for this function:

◆ m0_ext_sub()

M0_INTERNAL void m0_ext_sub ( const struct m0_ext minuend,
const struct m0_ext subtrahend,
struct m0_ext difference 
)

◆ M0_XCA_DOMAIN()

struct m0_ext M0_XCA_DOMAIN ( be rpc)

Variable Documentation

◆ M0_XCA_DOMAIN

enum m0_ext_format_version M0_XCA_DOMAIN