nyt

package
v0.0.0-...-fbee99c Latest Latest
Warning

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

Go to latest
Published: Mar 10, 2016 License: Apache-2.0 Imports: 8 Imported by: 0

README

Documentation

Overview

Package nyt is a generated protocol buffer package.

It is generated from these files:

mostpopular.proto
semanticconcept.proto

It has these top-level messages:

MostPopularResponse
MostPopularResult
Media
MediaMetadata
SemanticConceptResponse
SemanticConceptResult
SemanticConceptArticleList
SemanticConceptArticle

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client interface {
	GetMostPopular(string, string, uint) ([]*MostPopularResult, error)
	SemanticConceptSearch(string, string) ([]*SemanticConceptArticle, error)
}

func NewClient

func NewClient(mostPopToken, semanticToken string) Client

type ClientImpl

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

func (*ClientImpl) GetMostPopular

func (c *ClientImpl) GetMostPopular(resourceType string, section string, timePeriodDays uint) ([]*MostPopularResult, error)

func (*ClientImpl) SemanticConceptSearch

func (c *ClientImpl) SemanticConceptSearch(conceptType, concept string) ([]*SemanticConceptArticle, error)

type Media

type Media struct {
	Type          string           `protobuf:"bytes,1,opt,name=type" json:"type,omitempty"`
	Subtype       string           `protobuf:"bytes,2,opt,name=subtype" json:"subtype,omitempty"`
	Caption       string           `protobuf:"bytes,3,opt,name=caption" json:"caption,omitempty"`
	Copyright     string           `protobuf:"bytes,4,opt,name=copyright" json:"copyright,omitempty"`
	MediaMetadata []*MediaMetadata `protobuf:"bytes,5,rep,name=media_metadata" json:"media_metadata,omitempty"`
}

func (*Media) Descriptor

func (*Media) Descriptor() ([]byte, []int)

func (*Media) GetMediaMetadata

func (m *Media) GetMediaMetadata() []*MediaMetadata

func (*Media) ProtoMessage

func (*Media) ProtoMessage()

func (*Media) Reset

func (m *Media) Reset()

func (*Media) String

func (m *Media) String() string

type MediaMetadata

type MediaMetadata struct {
	Url    string `protobuf:"bytes,1,opt,name=url" json:"url,omitempty"`
	Format string `protobuf:"bytes,2,opt,name=format" json:"format,omitempty"`
	Height uint32 `protobuf:"varint,3,opt,name=height" json:"height,omitempty"`
	Width  uint32 `protobuf:"varint,4,opt,name=width" json:"width,omitempty"`
}

func (*MediaMetadata) Descriptor

func (*MediaMetadata) Descriptor() ([]byte, []int)

func (*MediaMetadata) ProtoMessage

func (*MediaMetadata) ProtoMessage()

func (*MediaMetadata) Reset

func (m *MediaMetadata) Reset()

func (*MediaMetadata) String

func (m *MediaMetadata) String() string

type MostPopularResponse

type MostPopularResponse struct {
	Status     string               `protobuf:"bytes,1,opt,name=status" json:"status,omitempty"`
	Copyright  string               `protobuf:"bytes,2,opt,name=copyright" json:"copyright,omitempty"`
	NumResults uint32               `protobuf:"varint,3,opt,name=num_results" json:"num_results,omitempty"`
	Result     []*MostPopularResult `protobuf:"bytes,4,rep,name=result" json:"result,omitempty"`
}

func (*MostPopularResponse) Descriptor

func (*MostPopularResponse) Descriptor() ([]byte, []int)

func (*MostPopularResponse) GetResult

func (m *MostPopularResponse) GetResult() []*MostPopularResult

func (*MostPopularResponse) ProtoMessage

func (*MostPopularResponse) ProtoMessage()

func (*MostPopularResponse) Reset

func (m *MostPopularResponse) Reset()

func (*MostPopularResponse) String

func (m *MostPopularResponse) String() string

type MostPopularResult

type MostPopularResult struct {
	Url           string   `protobuf:"bytes,1,opt,name=url" json:"url,omitempty"`
	Id            uint64   `protobuf:"varint,2,opt,name=id" json:"id,omitempty"`
	AsssetId      uint64   `protobuf:"varint,3,opt,name=assset_id" json:"assset_id,omitempty"`
	AdxKeywords   string   `protobuf:"bytes,4,opt,name=adx_keywords" json:"adx_keywords,omitempty"`
	Column        string   `protobuf:"bytes,5,opt,name=column" json:"column,omitempty"`
	Section       string   `protobuf:"bytes,6,opt,name=section" json:"section,omitempty"`
	Byline        string   `protobuf:"bytes,7,opt,name=byline" json:"byline,omitempty"`
	Type          string   `protobuf:"bytes,8,opt,name=type" json:"type,omitempty"`
	Title         string   `protobuf:"bytes,9,opt,name=title" json:"title,omitempty"`
	Abstract      string   `protobuf:"bytes,10,opt,name=abstract" json:"abstract,omitempty"`
	PublishedDate string   `protobuf:"bytes,11,opt,name=published_date" json:"published_date,omitempty"`
	Source        string   `protobuf:"bytes,12,opt,name=source" json:"source,omitempty"`
	Views         uint32   `protobuf:"varint,13,opt,name=views" json:"views,omitempty"`
	Media         []*Media `protobuf:"bytes,14,rep,name=media" json:"media,omitempty"`
}

func (*MostPopularResult) Descriptor

func (*MostPopularResult) Descriptor() ([]byte, []int)

func (*MostPopularResult) GetMedia

func (m *MostPopularResult) GetMedia() []*Media

func (*MostPopularResult) ProtoMessage

func (*MostPopularResult) ProtoMessage()

func (*MostPopularResult) Reset

func (m *MostPopularResult) Reset()

func (*MostPopularResult) String

func (m *MostPopularResult) String() string

type SemanticConceptArticle

type SemanticConceptArticle struct {
	Body   string `protobuf:"bytes,1,opt,name=body" json:"body,omitempty"`
	Byline string `protobuf:"bytes,2,opt,name=byline" json:"byline,omitempty"`
	Title  string `protobuf:"bytes,3,opt,name=title" json:"title,omitempty"`
	Url    string `protobuf:"bytes,4,opt,name=url" json:"url,omitempty"`
}

func (*SemanticConceptArticle) Descriptor

func (*SemanticConceptArticle) Descriptor() ([]byte, []int)

func (*SemanticConceptArticle) ProtoMessage

func (*SemanticConceptArticle) ProtoMessage()

func (*SemanticConceptArticle) Reset

func (m *SemanticConceptArticle) Reset()

func (*SemanticConceptArticle) String

func (m *SemanticConceptArticle) String() string

type SemanticConceptArticleList

type SemanticConceptArticleList struct {
	Result []*SemanticConceptArticle `protobuf:"bytes,1,rep,name=result" json:"result,omitempty"`
	Total  uint32                    `protobuf:"varint,2,opt,name=total" json:"total,omitempty"`
}

func (*SemanticConceptArticleList) Descriptor

func (*SemanticConceptArticleList) Descriptor() ([]byte, []int)

func (*SemanticConceptArticleList) GetResult

func (*SemanticConceptArticleList) ProtoMessage

func (*SemanticConceptArticleList) ProtoMessage()

func (*SemanticConceptArticleList) Reset

func (m *SemanticConceptArticleList) Reset()

func (*SemanticConceptArticleList) String

func (m *SemanticConceptArticleList) String() string

type SemanticConceptResponse

type SemanticConceptResponse struct {
	Status     string                   `protobuf:"bytes,1,opt,name=status" json:"status,omitempty"`
	Copyright  string                   `protobuf:"bytes,2,opt,name=copyright" json:"copyright,omitempty"`
	NumResults uint32                   `protobuf:"varint,3,opt,name=num_results" json:"num_results,omitempty"`
	Result     []*SemanticConceptResult `protobuf:"bytes,4,rep,name=result" json:"result,omitempty"`
}

func (*SemanticConceptResponse) Descriptor

func (*SemanticConceptResponse) Descriptor() ([]byte, []int)

func (*SemanticConceptResponse) GetResult

func (*SemanticConceptResponse) ProtoMessage

func (*SemanticConceptResponse) ProtoMessage()

func (*SemanticConceptResponse) Reset

func (m *SemanticConceptResponse) Reset()

func (*SemanticConceptResponse) String

func (m *SemanticConceptResponse) String() string

type SemanticConceptResult

type SemanticConceptResult struct {
	ArticleList *SemanticConceptArticleList `protobuf:"bytes,1,opt,name=article_list" json:"article_list,omitempty"`
}

func (*SemanticConceptResult) Descriptor

func (*SemanticConceptResult) Descriptor() ([]byte, []int)

func (*SemanticConceptResult) GetArticleList

func (*SemanticConceptResult) ProtoMessage

func (*SemanticConceptResult) ProtoMessage()

func (*SemanticConceptResult) Reset

func (m *SemanticConceptResult) Reset()

func (*SemanticConceptResult) String

func (m *SemanticConceptResult) String() string

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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