*: initial outlinings and LICENSE

Signed-off-by: Vincent Batts <vbatts@hashbangbash.com>
This commit is contained in:
Vincent Batts 2017-04-20 14:18:47 -04:00
parent bbdaf4851d
commit 71d8e2cb3a
Signed by: vbatts
GPG key ID: 10937E57733F1362
4 changed files with 68 additions and 0 deletions

28
LICENSE Normal file
View file

@ -0,0 +1,28 @@
Copyright (c) 2017 Vincent Batts, Raleigh, NC, USA
All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
1. Redistributions of source code must retain the above copyright notice, this
list of conditions and the following disclaimer.
2. Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimer in the documentation
and/or other materials provided with the distribution.
3. Neither the name of the copyright holder nor the names of its contributors
may be used to endorse or promote products derived from this software without
specific prior written permission.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

7
doc.go Normal file
View file

@ -0,0 +1,7 @@
// copyright (C) 2017 Vincent Batts. All rights reserved. Usage of this code
// is governed by the license found in the LICENSE file.
// Package storage is intended to the common interaction model for an untold
// number of backing graph or storage drivers, namely for application container
// image storage.
package storage

6
driver/driver.go Normal file
View file

@ -0,0 +1,6 @@
package driver
// Driver is the vfs level driver to operate on filesystem trees (i.e.
// copy-on-write filesystems, etc)
type Driver struct {
}

27
register.go Normal file
View file

@ -0,0 +1,27 @@
package storage
import "git.thisco.de/vbatts/image-storage-interfaces/driver"
// Drivers returns a sorted list of the registered drivers
func Drivers() []string {
return nil
}
// Register makes a database driver available by the provided name. If Register
// is called twice with the same name or if driver is nil, it panics.
func Register(name string, driver driver.Driver) {
}
// OpenHandle a storage handle using the specified storage driver name and a
// rootPath for that driver to operate in.
func OpenHandle(name string, rootPath string) (*S, error) {
return nil, nil
}
// S is a storage handle for the storage and management of filesystem trees.
//
// Operations on an handle instance are intended to be safe for concurrent use.
// Though this would likely not be safe for two competing instances to be
// operating on the same rootPath (more thought needed here).
type S struct {
}