/*-
* See the file LICENSE for redistribution information.
*
* Copyright (c) 2009 Oracle. All rights reserved.
*
*/
using System;
using System.Collections.Generic;
using System.Text;
namespace BerkeleyDB {
///
/// Statistical information about a BTreeDatabase
///
public class BTreeStats {
private Internal.BTreeStatStruct st;
internal BTreeStats(Internal.BTreeStatStruct stats) {
st = stats;
}
///
/// Duplicate pages.
///
public uint DuplicatePages { get { return st.bt_dup_pg; } }
///
/// Bytes free in duplicate pages.
///
public ulong DuplicatePagesFreeBytes { get { return st.bt_dup_pgfree; } }
///
/// Empty pages.
///
public uint EmptyPages { get { return st.bt_empty_pg; } }
///
/// Pages on the free list.
///
public uint FreePages { get { return st.bt_free; } }
///
/// Internal pages.
///
public uint InternalPages { get { return st.bt_int_pg; } }
///
/// Bytes free in internal pages.
///
public ulong InternalPagesFreeBytes { get { return st.bt_int_pgfree; } }
///
/// Leaf pages.
///
public uint LeafPages { get { return st.bt_leaf_pg; } }
///
/// Bytes free in leaf pages.
///
public ulong LeafPagesFreeBytes { get { return st.bt_leaf_pgfree; } }
///
/// Tree levels.
///
public uint Levels { get { return st.bt_levels; } }
///
/// Magic number.
///
public uint MagicNumber { get { return st.bt_magic; } }
///
/// Metadata flags.
///
public uint MetadataFlags { get { return st.bt_metaflags; } }
///
/// Minkey value.
///
public uint MinKey { get { return st.bt_minkey; } }
///
/// Number of data items.
///
public uint nData { get { return st.bt_ndata; } }
///
/// Number of unique keys.
///
public uint nKeys { get { return st.bt_nkeys; } }
///
/// Page count.
///
public uint nPages { get { return st.bt_pagecnt; } }
///
/// Overflow pages.
///
public uint OverflowPages { get { return st.bt_over_pg; } }
///
/// Bytes free in overflow pages.
///
public ulong OverflowPagesFreeBytes { get { return st.bt_over_pgfree; } }
///
/// Page size.
///
public uint PageSize { get { return st.bt_pagesize; } }
///
/// Version number.
///
public uint Version { get { return st.bt_version; } }
}
}