org.kohsuke.github
Class GHEventInfo

java.lang.Object
  extended by org.kohsuke.github.GHEventInfo

public class GHEventInfo
extends Object

Represents an event.

Author:
Kohsuke Kawaguchi

Nested Class Summary
static class GHEventInfo.GHEventRepository
          Inside the event JSON model, GitHub uses a slightly different format.
 
Constructor Summary
GHEventInfo()
           
 
Method Summary
 GHUser getActor()
           
 Date getCreatedAt()
           
 GHOrganization getOrganization()
           
<T extends GHEventPayload>
T
getPayload(Class<T> type)
          Retrieves the payload.
 GHRepository getRepository()
          Repository where the change was made.
 GHEvent getType()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

GHEventInfo

public GHEventInfo()
Method Detail

getType

public GHEvent getType()

getCreatedAt

public Date getCreatedAt()

getRepository

public GHRepository getRepository()
                           throws IOException
Repository where the change was made.

Throws:
IOException

getActor

public GHUser getActor()
                throws IOException
Throws:
IOException

getOrganization

public GHOrganization getOrganization()
                               throws IOException
Throws:
IOException

getPayload

public <T extends GHEventPayload> T getPayload(Class<T> type)
                                    throws IOException
Retrieves the payload.

Parameters:
type - Specify one of the GHEventPayload subtype that defines a type-safe access to the payload. This must match the event type.
Throws:
IOException


Copyright © 2012. All Rights Reserved.