mtp

package
v0.0.0-...-207d32a Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 30, 2023 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Overview

Package cmd provides command handlers

Copyright © 2020 Maksym Medvedev <redrathnure@gmail.com>

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

Constants

This section is empty.

Variables

View Source
var CAM_FILES_DIR string = path.Join("PRIVATE", "AVCHD", "BDMV", "STREAM")
View Source
var CopyProgressTemplate pb.ProgressBarTemplate = `` /* 193-byte string literal not displayed */
View Source
var DCIM_DIR string = "DCIM"
View Source
var DeletingProgressTemplate pb.ProgressBarTemplate = `` /* 166-byte string literal not displayed */
View Source
var GOPRO_DIR string = path.Join("DCIM", "100GOPRO")

Functions

func LoadCamVideos

func LoadCamVideos(targetDir string, dryRun bool) (string, error)

func LoadGoProVideos

func LoadGoProVideos(targetDir string, dryRun bool) (string, error)

func LoadSdPhotos

func LoadSdPhotos(targetDir string, dryRun bool) (string, error)

Types

type AndFilter

type AndFilter struct {
	// contains filtered or unexported fields
}

type ExecutionFileIterator

type ExecutionFileIterator struct {
	// contains filtered or unexported fields
}

func (*ExecutionFileIterator) Current

func (fileIt *ExecutionFileIterator) Current() *wpdFile

func (*ExecutionFileIterator) GetFilesCount

func (fileIt *ExecutionFileIterator) GetFilesCount() int

func (*ExecutionFileIterator) GetFilesTotal

func (fileIt *ExecutionFileIterator) GetFilesTotal() int

func (*ExecutionFileIterator) GetSizeLeft

func (fileIt *ExecutionFileIterator) GetSizeLeft() int64

func (*ExecutionFileIterator) HasNext

func (fileIt *ExecutionFileIterator) HasNext() bool

func (*ExecutionFileIterator) Next

func (fileIt *ExecutionFileIterator) Next() *wpdFile

type ExecutionPlan

type ExecutionPlan struct {
	// contains filtered or unexported fields
}

func BuildExecutionPlan

func BuildExecutionPlan(rootDirs []*wpdFile, wpdRootDir string) *ExecutionPlan

func (*ExecutionPlan) AddFile

func (executionPlan *ExecutionPlan) AddFile(file *wpdFile)

func (*ExecutionPlan) GetFileInterator

func (executionPlan *ExecutionPlan) GetFileInterator() *ExecutionFileIterator

func (*ExecutionPlan) GetFilesCount

func (executionPlan *ExecutionPlan) GetFilesCount() int

func (*ExecutionPlan) GetTotalSize

func (executionPlan *ExecutionPlan) GetTotalSize() int64

func (*ExecutionPlan) GetTotalSizeString

func (executionPlan *ExecutionPlan) GetTotalSizeString() string

func (*ExecutionPlan) IsEmpty

func (executionPlan *ExecutionPlan) IsEmpty() bool

type HasDeviceNameFilter

type HasDeviceNameFilter struct {
	// contains filtered or unexported fields
}

type HasFileFilter

type HasFileFilter struct {
	// contains filtered or unexported fields
}

type MtpDeviceFilter

type MtpDeviceFilter interface {
	// contains filtered or unexported methods
}
var CamFilter MtpDeviceFilter = AndFilter{[]MtpDeviceFilter{camDeviceNameFilter, streamFolderFilter}}
var GoProFilter MtpDeviceFilter = OrFilter{[]MtpDeviceFilter{heroDeviceNameFilter, goProDeviceNameFilter, _100GOPROFolderFilter}}
var SdPhotosFilter MtpDeviceFilter = AndFilter{[]MtpDeviceFilter{dcmiFilderFilter, NotFilter{GoProFilter}, NotFilter{CamFilter}}}

type MtpDownloader

type MtpDownloader struct {
	// contains filtered or unexported fields
}

func (*MtpDownloader) GetError

func (downloader *MtpDownloader) GetError() error

func (*MtpDownloader) GetResultDir

func (downloader *MtpDownloader) GetResultDir() string

func (*MtpDownloader) HasError

func (downloader *MtpDownloader) HasError() bool

type NotFilter

type NotFilter struct {
	// contains filtered or unexported fields
}

type OrFilter

type OrFilter struct {
	// contains filtered or unexported fields
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL