gallog

package
v1.1.0 Latest Latest
Warning

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

Go to latest
Published: Sep 28, 2019 License: GPL-3.0 Imports: 10 Imported by: 1

Documentation

Overview

Package gallog 는 디시인사이드 갤로그 관련 API를 제공합니다.

갤로그는 디시인사이드에서 제공하는 공식 API가 없기 때문에 Web을 파싱하는 방법으로 API를 구현하였습니다.

gallog 패키지로 구현한 디시인사이드 클리너는 아래 링크에서 확인할 수 있습니다.

https://github.com/geeksbaek/goinside-gallog-cleaner

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type GallogItems

type GallogItems []string

type Session

type Session struct {
	*goinside.MemberSessionDetail
	// contains filtered or unexported fields
}

Session 구조체는 갤로그 세션 정보를 나타냅니다.

func Login

func Login(id, pw string) (s *Session, err error)

Login 함수는 해당 ID와 PASSWORD로 로그인한 뒤 해당 세션을 반환합니다.

func (*Session) DeleteAll

func (s *Session) DeleteAll(max int, data GallogItems, cb func(i, n int))

DeleteAll 메소드는 해당 데이터를 모두 삭제합니다. 데이터 삭제 상황을 확인할 수 있도록 콜백 함수를 인자로 받습니다. 해당 콜백 함수는 삭제된 데이터 개수 i과 총 데이터 개수 n을 인자로 받습니다.

func (*Session) FetchAll

func (s *Session) FetchAll(max int, progressCh chan struct{}) (data GallogItems)

FetchAll 메소드는 해당 세션의 갤로그에 존재하는 모든 데이터를 가져옵니다.

func (*Session) Logout

func (s *Session) Logout() (err error)

Logout 메소드는 해당 세션을 종료합니다.

Jump to

Keyboard shortcuts

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