Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type FileUploadResponse ¶
type FileUploadResponse struct { EID string `json:"eid,omitempty"` Domain string `json:"domain,omitempty"` Department string `json:"department,omitempty"` DocName string `json:"doc_name,omitempty"` DocCategory string `json:"doc_category,omitempty"` DocType string `json:"doc_type,omitempty"` DocPath string `json:"doc_path,omitempty"` }
type StorageConnection ¶
func NewStorageConnection ¶
func NewStorageConnection() *StorageConnection
GetGCSClient gets singleton object for Google Storage
func (*StorageConnection) CreateBucket ¶
func (a *StorageConnection) CreateBucket(domain string) error
func (*StorageConnection) DownloadFile ¶
func (a *StorageConnection) DownloadFile(w http.ResponseWriter, r *http.Request, domain string) error
Download gets a file from GCS bucket, Takes file path as a path param from request
func (*StorageConnection) UploadFile ¶
func (a *StorageConnection) UploadFile(r *http.Request, domain string) (FileUploadResponse, error)
Click to show internal directories.
Click to hide internal directories.