Documentation ¶
Overview ¶
Copyright 2019 The DutchSec Authors.
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Copyright 2019 The DutchSec Authors.
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Copyright 2019 The DutchSec Authors.
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Copyright 2019 The DutchSec Authors.
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Copyright 2019 The DutchSec Authors.
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Copyright 2019 The DutchSec Authors.
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Copyright 2019 The DutchSec Authors.
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Copyright 2019 The DutchSec Authors.
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Copyright 2019 The DutchSec Authors.
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Copyright 2019 The DutchSec Authors.
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Copyright 2019 The DutchSec Authors.
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Copyright 2019 The DutchSec Authors.
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Copyright 2019 The DutchSec Authors.
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Copyright 2019 The DutchSec Authors.
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Copyright 2019 The DutchSec Authors.
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Copyright 2019 The DutchSec Authors.
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Copyright 2019 The DutchSec Authors.
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Copyright 2019 The DutchSec Authors.
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Copyright 2019 The DutchSec Authors.
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Copyright 2019 The DutchSec Authors.
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Copyright 2019 The DutchSec Authors.
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Copyright 2019 The DutchSec Authors.
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Copyright 2019 The DutchSec Authors.
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Copyright 2019 The DutchSec Authors.
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Copyright 2019 The DutchSec Authors.
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Index ¶
- Variables
- func DiscardLogging()
- func IsDuplicateKeyErr(err error) bool
- func IsNoRowsErr(err error) bool
- func IsTxDoneErr(err error) bool
- func RandomString(length int) string
- func SubQuery(v interface{}) subQuery
- type Builder
- type DB
- type Deleter
- type Field
- type Getter
- type InsertOrUpdater
- type Inserter
- type New
- type Newerer
- type Operator
- func Active() Operator
- func And(operators ...Operator) Operator
- func Equal(left interface{}, right interface{}) Operator
- func False(fld Field) Operator
- func GreaterThan(field Field, value interface{}) Operator
- func In(field Field, params []interface{}) Operator
- func InOperator(field Field, qry Queryx) Operator
- func IsNotNull(field Field) Operator
- func IsNull(field Field) Operator
- func LessThan(field Field, value interface{}) Operator
- func Like(left interface{}, right interface{}) Operator
- func Not(o Operator) Operator
- func Or(operators ...Operator) Operator
- func True(fld Field) Operator
- type Query
- type Queryx
- func (tq Queryx) Build() (Query, []interface{})
- func (tq Queryx) CountRows() Queryx
- func (tq Queryx) Dump() string
- func (tq Queryx) Fields(fields ...Field) Queryx
- func (tq Queryx) GroupBy(fields ...Field) Queryx
- func (tq Queryx) Join(tableName string) tableJoinQuery
- func (tq Queryx) LeftJoin(tableName string) tableJoinQuery
- func (tq Queryx) Limit(offset, count int) Queryx
- func (tq Queryx) OrderBy(fields ...Field) Queryx
- func (tq Queryx) OrderByDesc(fields ...Field) Queryx
- func (tq Queryx) RightJoin(tableName string) tableJoinQuery
- func (tq Queryx) Where(operator Operator) Queryx
- type Selecter
- type Table
- type Tx
- func (tx *Tx) Commit() error
- func (tx *Tx) Countx(qy Queryx) (int, error)
- func (tx *Tx) Delete(o interface{}) error
- func (tx *Tx) Execute(qy Queryx) error
- func (tx *Tx) Exists(qy Queryx) (bool, error)
- func (tx *Tx) Getx(o interface{}, qy Queryx) error
- func (tx *Tx) Insert(o interface{}) error
- func (tx *Tx) InsertOrUpdate(o interface{}) error
- func (tx *Tx) NamedExec(query string, arg interface{}) (sql.Result, error)
- func (tx *Tx) Preparex(query Query) (*sqlx.Stmt, error)
- func (tx *Tx) Rollback() error
- func (tx *Tx) Selectx(o interface{}, qy Queryx, options ...selectOption) error
- func (tx *Tx) Update(o interface{}) error
- type TxOptionFunc
- type Updater
Constants ¶
This section is empty.
Variables ¶
var ( ErrNoGetterFound = errors.New("No Getter found") ErrNoDeleterFound = errors.New("No Deleter found") ErrNoSelecterFound = errors.New("No Select found") ErrNoInsertOrUpdaterFound = errors.New("No InsertOrUpdater found") ErrNoUpdaterFound = errors.New("No Updater found") ErrNoInserterFound = errors.New("No Inserter found") )
TODO: NEEDS COMMENT INFO
Functions ¶
func DiscardLogging ¶
func DiscardLogging()
func IsDuplicateKeyErr ¶
func IsNoRowsErr ¶
func IsTxDoneErr ¶
func RandomString ¶
Types ¶
type InsertOrUpdater ¶
type New ¶
type New struct {
// contains filtered or unexported fields
}
New TODO: NEEDS COMMENT INFO
type Newerer ¶
type Newerer interface {
// contains filtered or unexported methods
}
Newerer TODO: NEEDS COMMENT INFO
type Operator ¶
type Operator interface {
Make() (string, []interface{})
}
Operator TODO: NEEDS COMMENT INFO
func Equal ¶
func Equal(left interface{}, right interface{}) Operator
Equal TODO: NEEDS COMMENT INFO
func GreaterThan ¶
GreaterThan TODO: NEEDS COMMENT INFO
func InOperator ¶
OrOperator TODO: NEEDS COMMENT INFO
type Queryx ¶
type Queryx struct {
// contains filtered or unexported fields
}
func DeleteQuery ¶
func SelectQuery ¶
func (Queryx) OrderBy ¶
TODO: keep track of fields on construct at once, make it an arry Query().OrderBy(fld).OrderByDesc(fld2)
func (Queryx) OrderByDesc ¶
TODO: keep track of fields on construct at once, make it an arry
type Tx ¶
Tx TODO: NEEDS COMMENT INFO
func (*Tx) Execute ¶
Exec TODO: NEEDS COMMENT INFO
func (tx *Tx) Exec(qx Queryx) error { stmt, err := tx.Preparex(qx.Query) if err != nil { return err } _, err = stmt.Exec(qx.Params...) return err }
func (*Tx) InsertOrUpdate ¶
Update TODO: NEEDS COMMENT INFO
type TxOptionFunc ¶
func ReadOnly ¶
func ReadOnly() TxOptionFunc