zftp

package module
v0.0.0-...-98ff1c3 Latest Latest
Warning

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

Go to latest
Published: Jun 25, 2016 License: MIT Imports: 8 Imported by: 0

README

zftp

Golang client for z/OS FTP server

zftp is forked from github.com/jlaffaye/ftp and makes some changes to accommdate to z/OS FTP server

Currently zftp only supports z/OS FTP server with JESINTERFACELEVEL=2

Install

go get github.com/thinkhy/zftp

Example

package main

import (
        "fmt"
        "os"
        "github.com/thinkhy/zftp"
       )

func main() {
	// TODO
}

Reference

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Job

type Job struct {
	Jobname string `bson:"jobname,omitempty" json:"jobname,omitempty"`
	Jobid   string `bson:"jobid,omitempty" json:"jobid,omitempty"`
	Owner   string `bson:"owner,omitempty" json:"owner,omitempty"`
	Status  string `bson:"status,omitempty" json:"status,omitempty"`
	Class   string `bson:"class,omitempty" json:"class,omitempty"`
}

JOBNAME JOBID OWNER STATUS CLASS

type Zftp

type Zftp struct {
	*ftp.ServerConn
}

func Dial

func Dial(adr string, timeout time.Duration) (*Zftp, error)

func (*Zftp) DeleteUnixFile

func (z *Zftp) DeleteUnixFile(remote string) (err error)

func (*Zftp) GetJobLog

func (z *Zftp) GetJobLog(jobid string) (r io.ReadCloser, err error)

func (*Zftp) GetJobStatusByID

func (z *Zftp) GetJobStatusByID(jobid string) (j *Job, err error)

func (*Zftp) GetJobStatusByName

func (z *Zftp) GetJobStatusByName(jobid string) (status string, err error)

func (*Zftp) GetJoblogByID

func (z *Zftp) GetJoblogByID(jobid string) (joblog string, err error)

func (*Zftp) GetPdsDataset

func (z *Zftp) GetPdsDataset(dataset, dir string) (err error)

func (*Zftp) GetPsDataset

func (z *Zftp) GetPsDataset(dataset string) (r io.ReadCloser, err error)

func (*Zftp) GetUnixFile

func (z *Zftp) GetUnixFile(remote string) (r io.ReadCloser, err error)

func (*Zftp) PurgeJob

func (z *Zftp) PurgeJob(jobid string) (err error)

func (*Zftp) PutUnixFile

func (z *Zftp) PutUnixFile(r io.Reader, remote string) (err error)

func (*Zftp) SetAsciiType

func (z *Zftp) SetAsciiType() (err error)

func (*Zftp) SetBinaryType

func (z *Zftp) SetBinaryType() (err error)

func (*Zftp) SetJesMode

func (z *Zftp) SetJesMode() (err error)

func (*Zftp) SetSeqMode

func (z *Zftp) SetSeqMode() (err error)

func (*Zftp) SubmitJob

func (z *Zftp) SubmitJob(r io.Reader) (jobid string, err error)

The z/OS FTP server supports only the CRLF("\r\n") value for incoming ASCII data.

func (*Zftp) SubmitRemoteJob

func (z *Zftp) SubmitRemoteJob(dataset string) (jobid string, err error)

func (*Zftp) Unix2Dos

func (z *Zftp) Unix2Dos(text string) string

Directories

Path Synopsis
Package ftp implements a FTP client as described in RFC 959.
Package ftp implements a FTP client as described in RFC 959.

Jump to

Keyboard shortcuts

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