Skip to main content

Crate elephantry

Crate elephantry 

Source
Expand description

Foreign types (ie defined in another crate), have type alias.

SQL typeRust typeFeature
bigint/int8i64
bitu8bit
bit(n)[u8; n]bit
bit varyingbit_vec::BitVec
elephantry::Bits
bit
booleanbool
boxelephantry::Boxgeo
byteaelephantry::Bytea
charchar
varcharString
cidripnetwork::IpNetwork
elephantry::Cidr
net
circleelephantry::Circlegeo
datechrono::NaiveDate
elephantry::Date
jiff::civil::Date
date

jiff
double precision/float8f64
hstoreelephantry::Hstore
inetstd::net::IpAddrnet
integer/int4i32
intervalelephantry::Intervaldate
jsonserde_json::Value
elephantry::Json
json
jsonbelephantry::Jsonbjson
lineelephantry::Linegeo
lqueryelephantry::Lqueryltree
lsegelephantry::Segmentgeo
ltreeelephantry::Ltreeltree
ltxtqueryelephantry::Ltxtqueryltree
null()
macaddrmacaddr::MacAddr6
elephantry::MacAddr
net
macaddr8macaddr::MacAddr8
elephantry::MacAddr8
net
moneypostgres_money::Money
elephantry::Money
money
multirangeelephantry::Multirangemultirange
numericbigdecimal::BigDecimal
elephantry::Numeric
numeric
pathelephantry::Pathgeo
pointelephantry::Pointgeo
polygonelephantry::Polygongeo
real/float4f32
recordtuple
smallint/int2i16
textString
timeelephantry::Time
time::Time
chrono::NaiveTime
jiff::civil::Time
time

chrono
jiff
timetzelephantry::TimeTz
(chrono::NaiveTime, chrono::FixedOffset)
(jiff::civil::Time, jiff::tz::TimeZone)
time
chrono
jiff
timestampchrono::NaiveDateTime
elephantry::Timestamp
jiff::civil::DateTime
date

jiff
timestamptzchrono::DateTime
elephantry::Timestamp
jiff::Zoned
date

jiff
uuiduuid::Uuid
elephantry::Uid
uuid
xmlxmltree::Element
elephantry::Xml
xml
[x, y)std::ops::Range
[x,)std::ops::RangeFrom
[,y)std::ops::RangeTo
(,)std::ops::RangeFull

Re-exports§

pub use crate::config::Config;
pub use connection::Connection;
pub use entity::Entity;
pub use from_sql::FromSql;
pub use to_sql::ToSql;
pub use transaction::Transaction;
pub use where::Where;

Modules§

config
connection
entity
from_sql
inspectinspect
database inspection module.
pq
libpq abstraction layer.
r2d2r2d2
to_sql
transaction
where

Macros§

pk
Easily create pk argument for where clause, including find_by_pk function.
values
Likes pk macro but for value argument, including update_by_pk function.

Structs§

Array
Rust type for array.
Async
This struct is created by the Connection::async method.
Boxgeo
Rust type for box.
Bytea
Rust type for bytea.
Circlegeo
Rust type for circle.
Coordinategeo
Coordinatesgeo
Hstore
Rust type for hstore.
Intervaldate and (chrono or jiff)
Rust type for interval.
Jsonbjson
Rust type for jsonb.
Linegeo
Rust type for line.
Lqueryltree
Ltreeltree
Ltxtqueryltree
Multirangemultirange
Notify
Pager
This struct is created by the Connection::paginate_find_where method.
Pathgeo
Rust type for path.
Pointgeo
Rust type for point.
Polygongeo
Rust type for polygon.
Pool
Connections pool.
Projection
Define the content of SELECT or RETURNING (projection) statements.
Rows
Represent a rows of result.
Segmentgeo
Rust type for segment.
Tuple
Represent a set of values, a row of results.

Enums§

Error

Traits§

FromText
Model
Impl this trait to create a link between an entity and a structure.
Projectable
Structure
Trait to reflect relation structure.
ToText

Type Aliases§

Bitsbit
Rust type for varbit.
Cidrnet
Rust type for cidr.
Datechrono and date and (chrono or jiff)
Rust type for date.
Jsonjson
Rust type for json.
MacAddrnet
Rust type for macaddr.
MacAddr8net
Rust type for macaddr8.
Moneymoney
Rust type for money.
Numericnumeric
Rust type for numeric.
Result
Timetime and (chrono or jiff or time)
Rust type for time.
TimeTztime and (chrono or jiff or time)
Rust type for timetz.
Timestampchrono and date and (chrono or jiff)
Rust type for date.
TimestampTzchrono and date and (chrono or jiff)
Rust type for timestamptz.
Timezonetime and (chrono or jiff or time)
Uuiduuid
Rust type for uuid.
Xmlxml
Rust type for xml.

Derive Macros§

Composite
Impl FromSql/ToSql traits for composite type.
Entity
Impl Entity trait.
Enum
Impl FromSql/ToSql traits for enum type.