PHP Class Knp\Bundle\KnpBundlesBundle\Entity\Bundle

Afficher le fichier Open project: KnpLabs/KnpBundles Class Usage Examples

Protected Properties

Свойство Type Description
$activities Doctrine\Common\Collections\Collection
$canonicalConfig The bundle canonical configuration yaml extracted from bundle's repo
$composerName Composer name
$contributors Doctrine\Common\Collections\Collection Developers who contributed to the Repo
$createdAt Repo creation date (on this website)
$description Repo description
$favorers Doctrine\Common\Collections\Collection Developers who has favorited the bundle
$homepage The website url, if any
$id
$indexedAt Last indexing time.
$isFork True if the Repo is a fork
$keywords Doctrine\Common\Collections\Collection Bundle keywords
$lastCheckAt Date of the last successful GitHub check
$lastCommitAt Date of the last Git commit
$lastTweetedAt Date when bundle was tweeted from knplabs account.
$license The bundle license text extracted from source code
$licenseType The bundle license type extracted from composer.json
$name Repo name, e.g. "MarkdownBundle" Like in GitHub, this name is not unique
$nbFavorers
$nbFollowers Number of GitHub followers
$nbForks Number of GitHub forks
$nbRecommenders
$owner Doctrine\Common\Collections\Collection Owner of the bundle
$ownerName The name of the owner who owns this bundle This value is redundant with the name of the referenced Owner, for performance reasons
$ownerType The type of the owner who owns this bundle This value is redundant with the class of the referenced Owner, for performance reasons
$readme The bundle readme text extracted from source code
$recommenders Doctrine\Common\Collections\Collection Developers recommending the bundle
$score Internal score of the Repo, based on several indicators Defines the Repo position in lists and searches
$scoreDetails array Latest score's details
$scores Doctrine\Common\Collections\Collection Internal scores
$state Status of bundle
$travisCiBuildStatus Travis Ci last build status
$trend1 Trend over the last day. Max is better.
$updatedAt Repo update date (on this website)
$usesTravisCi True if the Repo uses Travis CI
$versionsHistory Bundle versions history

Méthodes publiques

Méthode Description
__construct ( null | string $fullName = null )
__toString ( )
addActivity ( Activity $activity )
addFavorer ( Developer $developer )
addKeyword ( Keyword $keyword )
addRecommender ( Developer $developer )
addScoreDetail ( $name, $value )
countKeywords ( ) : integer
fromArray ( array $data )
getActivities ( null | integer $page = null, integer $limit = 15 ) : Traversable Get activities
getCanonicalConfig ( ) : string Get canonicalConfig
getClass ( )
getComposerName ( ) : string Get Composer name
getContributorNames ( )
getContributors ( null | integer $page = null, integer $limit = 20 ) : Traversable Get contributors
getCreatedAt ( ) : DateTime Get the bundle creation date
getDaysSinceLastCommit ( ) : integer Returns the number of days elapsed since the last commit on the master branch
getDescription ( null | integer $cutAfter = null ) : string Get description
getFavorers ( null | integer $page = null, integer $limit = 20 ) : Traversable
getFullName ( ) : string Get full name, including ownerName
getGitHubUrl ( ) : string Get the GitHub url of this bundle
getGitUrl ( ) : string Get the Git repo url
getHomepage ( ) : string Get homepage
getId ( ) : string Get id
getIndexedAt ( ) : DateTime Get indexedAt
getIsFork ( ) : boolean Get isFork
getKeywords ( ) : Doctrine\Common\Collections\Collection
getLastCheckAt ( ) : DateTime Get the date of last check
getLastCommitAt ( ) : DateTime Get the date of the last commit
getLastTweetedAt ( ) : null | DateTime Get lastTweetedAt
getLatestActivities ( $type = Activity::ACTIVITY_TYPE_COMMIT )
getLatestScoreDetails ( )
getLicense ( ) : string Get license data
getLicenseType ( ) : string Get license type
getName ( ) : string Get name
getNbContributors ( ) : integer Get the number of contributors
getNbFavorers ( )
getNbFollowers ( ) : integer Get followers
getNbForks ( ) : integer Get forks
getNbRecommenders ( )
getOwner ( ) : Owner
getOwnerName ( ) : string Get ownername
getOwnerType ( ) : string
getPackagistUrl ( ) : string Get the Packagist url of this repo
getReadme ( ) : string Get readme
getRecommenders ( null | integer $page = null, integer $limit = 20 ) : Traversable
getScore ( ) : integer Get score
getScoreDetails ( ) Returns details about the bundle's score
getScores ( integer $limit = null ) : array Get all historical scores indexed by date
getShortName ( ) : string Get the first part of the name, without Bundle
getState ( ) : string Get the status of bundle
getStatusHash ( ) : string Unique string which shows current status of the bundle
getSymfonyVersions ( ) : array | null Get required versions of Symfony from bundle Versions History
getTravisCiBuildStatus ( ) : string Get Travis Ci last build status
getTravisUrl ( ) : string Get the Travis Ci url of this bundle
getTrend1 ( ) : integer Get the trend over the last day
getUpdatedAt ( ) : DateTime Get the bundle update date
getUsesTravisCi ( ) : boolean Get whether bundle uses Travis CI
getVersionsHistory ( ) : array Get bundle versions history
hasChanges ( ) : boolean
hasKeyword ( Keyword $keyword ) : boolean
isInitialized ( )
isOwnerOrContributor ( Owner $owner ) : boolean
markAsCreated ( )
markAsUpdated ( )
recalculateScore ( ) Calculate the score of this bundle based on several factors.
removeFavorer ( Developer $developer )
removeRecommender ( Developer $developer )
setCanonicalConfig ( $canonicalConfig ) Set canonicalConfig
setComposerName ( $name ) Set Composer name
setContributors ( array $contributors ) Set contributors
setCreatedAt ( DateTime $createdAt ) Set the bundle creation date
setDescription ( string $description ) Set description
setHomepage ( string $homepage ) Set homepage
setIndexedAt ( DateTime $indexedAt ) Set indexedAt
setIsFork ( boolean $isFork ) Set isFork
setLastCheckAt ( DateTime $lastCheckAt ) Set the date of last check
setLastCommitAt ( DateTime $lastCommitAt ) Set lastCommitAt
setLastTweetedAt ( DateTime $lastTweetedAt ) Set lastTweetedAt
setLicense ( string $license ) Set license data
setLicenseType ( string $license ) Set license type
setName ( $name ) Set name
setNbFavorers ( integer $nbFavorers )
setNbFollowers ( integer $nbFollowers ) Set followers
setNbForks ( integer $nbForks ) Set forks
setNbRecommenders ( integer $nbRecommenders )
setOwner ( Owner $owner )
setOwnerName ( string $ownerName ) Set ownerName
setReadme ( string $readme ) Set readme
setScore ( integer $score ) Set score
setScoreDetails ( array $details )
setState ( $state ) Set status of bundle
setTravisCiBuildStatus ( string $status ) Set Travis Ci last build status
setUsesTravisCi ( boolean $uses ) Set whether bundle uses Travis CI
setVersionsHistory ( array $versions ) Set bundle versions history
toBigArray ( ) : array Get an array representing the Repo
toSmallArray ( )
updateScore ( integer $points = 1 ) Updates bundle score with given amount of points

Method Details

__construct() public méthode

public __construct ( null | string $fullName = null )
$fullName null | string

__toString() public méthode

public __toString ( )

addActivity() public méthode

public addActivity ( Activity $activity )
$activity Activity

addFavorer() public méthode

public addFavorer ( Developer $developer )
$developer Developer

addKeyword() public méthode

public addKeyword ( Keyword $keyword )
$keyword Keyword

addRecommender() public méthode

public addRecommender ( Developer $developer )
$developer Developer

addScoreDetail() public méthode

public addScoreDetail ( $name, $value )

countKeywords() public méthode

public countKeywords ( ) : integer
Résultat integer Total nb of keywords for this bundle

fromArray() public méthode

public fromArray ( array $data )
$data array

getActivities() public méthode

Get activities
public getActivities ( null | integer $page = null, integer $limit = 15 ) : Traversable
$page null | integer
$limit integer
Résultat Traversable

getCanonicalConfig() public méthode

Get canonicalConfig
public getCanonicalConfig ( ) : string
Résultat string

getClass() public méthode

public getClass ( )

getComposerName() public méthode

Get Composer name
public getComposerName ( ) : string
Résultat string

getContributorNames() public méthode

public getContributorNames ( )

getContributors() public méthode

Get contributors
public getContributors ( null | integer $page = null, integer $limit = 20 ) : Traversable
$page null | integer
$limit integer
Résultat Traversable

getCreatedAt() public méthode

Get the bundle creation date
public getCreatedAt ( ) : DateTime
Résultat DateTime

getDaysSinceLastCommit() public méthode

Returns the number of days elapsed since the last commit on the master branch
public getDaysSinceLastCommit ( ) : integer
Résultat integer

getDescription() public méthode

Get description
public getDescription ( null | integer $cutAfter = null ) : string
$cutAfter null | integer
Résultat string

getFavorers() public méthode

public getFavorers ( null | integer $page = null, integer $limit = 20 ) : Traversable
$page null | integer
$limit integer
Résultat Traversable

getFullName() public méthode

Get full name, including ownerName
public getFullName ( ) : string
Résultat string

getGitHubUrl() public méthode

Get the GitHub url of this bundle
public getGitHubUrl ( ) : string
Résultat string

getGitUrl() public méthode

Get the Git repo url
public getGitUrl ( ) : string
Résultat string

getHomepage() public méthode

Get homepage
public getHomepage ( ) : string
Résultat string

getId() public méthode

Get id
public getId ( ) : string
Résultat string

getIndexedAt() public méthode

Get indexedAt
public getIndexedAt ( ) : DateTime
Résultat DateTime

getIsFork() public méthode

Get isFork
public getIsFork ( ) : boolean
Résultat boolean

getKeywords() public méthode

public getKeywords ( ) : Doctrine\Common\Collections\Collection
Résultat Doctrine\Common\Collections\Collection

getLastCheckAt() public méthode

Get the date of last check
public getLastCheckAt ( ) : DateTime
Résultat DateTime

getLastCommitAt() public méthode

Get the date of the last commit
public getLastCommitAt ( ) : DateTime
Résultat DateTime

getLastTweetedAt() public méthode

Get lastTweetedAt
public getLastTweetedAt ( ) : null | DateTime
Résultat null | DateTime

getLatestActivities() public méthode

public getLatestActivities ( $type = Activity::ACTIVITY_TYPE_COMMIT )

getLatestScoreDetails() public méthode

getLicense() public méthode

Get license data
public getLicense ( ) : string
Résultat string

getLicenseType() public méthode

Get license type
public getLicenseType ( ) : string
Résultat string

getName() public méthode

Get name
public getName ( ) : string
Résultat string

getNbContributors() public méthode

Get the number of contributors
public getNbContributors ( ) : integer
Résultat integer

getNbFavorers() public méthode

public getNbFavorers ( )

getNbFollowers() public méthode

Get followers
public getNbFollowers ( ) : integer
Résultat integer

getNbForks() public méthode

Get forks
public getNbForks ( ) : integer
Résultat integer

getNbRecommenders() public méthode

public getNbRecommenders ( )

getOwner() public méthode

public getOwner ( ) : Owner
Résultat Owner

getOwnerName() public méthode

Get ownername
public getOwnerName ( ) : string
Résultat string

getOwnerType() public méthode

public getOwnerType ( ) : string
Résultat string

getPackagistUrl() public méthode

Get the Packagist url of this repo
public getPackagistUrl ( ) : string
Résultat string

getReadme() public méthode

Get readme
public getReadme ( ) : string
Résultat string

getRecommenders() public méthode

public getRecommenders ( null | integer $page = null, integer $limit = 20 ) : Traversable
$page null | integer
$limit integer
Résultat Traversable

getScore() public méthode

Get score
public getScore ( ) : integer
Résultat integer

getScoreDetails() public méthode

Returns details about the bundle's score
public getScoreDetails ( )

getScores() public méthode

Get all historical scores indexed by date
public getScores ( integer $limit = null ) : array
$limit integer
Résultat array

getShortName() public méthode

Get the first part of the name, without Bundle
public getShortName ( ) : string
Résultat string

getState() public méthode

Get the status of bundle
public getState ( ) : string
Résultat string

getStatusHash() public méthode

Unique string which shows current status of the bundle
public getStatusHash ( ) : string
Résultat string

getSymfonyVersions() public méthode

Get required versions of Symfony from bundle Versions History
public getSymfonyVersions ( ) : array | null
Résultat array | null

getTravisCiBuildStatus() public méthode

Get Travis Ci last build status
public getTravisCiBuildStatus ( ) : string
Résultat string

getTravisUrl() public méthode

Get the Travis Ci url of this bundle
public getTravisUrl ( ) : string
Résultat string

getTrend1() public méthode

Get the trend over the last day
public getTrend1 ( ) : integer
Résultat integer

getUpdatedAt() public méthode

Get the bundle update date
public getUpdatedAt ( ) : DateTime
Résultat DateTime

getUsesTravisCi() public méthode

Get whether bundle uses Travis CI
public getUsesTravisCi ( ) : boolean
Résultat boolean

getVersionsHistory() public méthode

Get bundle versions history
public getVersionsHistory ( ) : array
Résultat array

hasChanges() public méthode

public hasChanges ( ) : boolean
Résultat boolean

hasKeyword() public méthode

public hasKeyword ( Keyword $keyword ) : boolean
$keyword Keyword
Résultat boolean

isInitialized() public méthode

public isInitialized ( )

isOwnerOrContributor() public méthode

public isOwnerOrContributor ( Owner $owner ) : boolean
$owner Owner
Résultat boolean

markAsCreated() public méthode

public markAsCreated ( )

markAsUpdated() public méthode

public markAsUpdated ( )

recalculateScore() public méthode

The score is used as the default sort field in many places. #TODO discuss me, improve me
public recalculateScore ( )

removeFavorer() public méthode

public removeFavorer ( Developer $developer )
$developer Developer

removeRecommender() public méthode

public removeRecommender ( Developer $developer )
$developer Developer

setCanonicalConfig() public méthode

Set canonicalConfig
public setCanonicalConfig ( $canonicalConfig )
$canonicalConfig

setComposerName() public méthode

Set Composer name
public setComposerName ( $name )

setContributors() public méthode

Set contributors
public setContributors ( array $contributors )
$contributors array

setCreatedAt() public méthode

Set the bundle creation date
public setCreatedAt ( DateTime $createdAt )
$createdAt DateTime

setDescription() public méthode

Set description
public setDescription ( string $description )
$description string

setHomepage() public méthode

Set homepage
public setHomepage ( string $homepage )
$homepage string

setIndexedAt() public méthode

Set indexedAt
public setIndexedAt ( DateTime $indexedAt )
$indexedAt DateTime

setIsFork() public méthode

Set isFork
public setIsFork ( boolean $isFork )
$isFork boolean

setLastCheckAt() public méthode

Set the date of last check
public setLastCheckAt ( DateTime $lastCheckAt )
$lastCheckAt DateTime

setLastCommitAt() public méthode

Set lastCommitAt
public setLastCommitAt ( DateTime $lastCommitAt )
$lastCommitAt DateTime

setLastTweetedAt() public méthode

Set lastTweetedAt
public setLastTweetedAt ( DateTime $lastTweetedAt )
$lastTweetedAt DateTime

setLicense() public méthode

Set license data
public setLicense ( string $license )
$license string

setLicenseType() public méthode

Set license type
public setLicenseType ( string $license )
$license string

setName() public méthode

Set name
public setName ( $name )

setNbFavorers() public méthode

public setNbFavorers ( integer $nbFavorers )
$nbFavorers integer

setNbFollowers() public méthode

Set followers
public setNbFollowers ( integer $nbFollowers )
$nbFollowers integer

setNbForks() public méthode

Set forks
public setNbForks ( integer $nbForks )
$nbForks integer

setNbRecommenders() public méthode

public setNbRecommenders ( integer $nbRecommenders )
$nbRecommenders integer

setOwner() public méthode

public setOwner ( Owner $owner )
$owner Owner

setOwnerName() public méthode

Set ownerName
public setOwnerName ( string $ownerName )
$ownerName string

setReadme() public méthode

Set readme
public setReadme ( string $readme )
$readme string

setScore() public méthode

Set score
public setScore ( integer $score )
$score integer

setScoreDetails() public méthode

public setScoreDetails ( array $details )
$details array

setState() public méthode

Set status of bundle
public setState ( $state )

setTravisCiBuildStatus() public méthode

Set Travis Ci last build status
public setTravisCiBuildStatus ( string $status )
$status string

setUsesTravisCi() public méthode

Set whether bundle uses Travis CI
public setUsesTravisCi ( boolean $uses )
$uses boolean

setVersionsHistory() public méthode

Set bundle versions history
public setVersionsHistory ( array $versions )
$versions array

toBigArray() public méthode

Get an array representing the Repo
public toBigArray ( ) : array
Résultat array

toSmallArray() public méthode

public toSmallArray ( )

updateScore() public méthode

Updates bundle score with given amount of points
public updateScore ( integer $points = 1 )
$points integer

Property Details

$activities protected_oe property

protected Collection,Doctrine\Common\Collections $activities
Résultat Doctrine\Common\Collections\Collection

$canonicalConfig protected_oe property

The bundle canonical configuration yaml extracted from bundle's repo
protected $canonicalConfig

$composerName protected_oe property

Composer name
protected $composerName

$contributors protected_oe property

Developers who contributed to the Repo
protected Collection,Doctrine\Common\Collections $contributors
Résultat Doctrine\Common\Collections\Collection

$createdAt protected_oe property

Repo creation date (on this website)
protected $createdAt

$description protected_oe property

Repo description
protected $description

$favorers protected_oe property

Developers who has favorited the bundle
protected Collection,Doctrine\Common\Collections $favorers
Résultat Doctrine\Common\Collections\Collection

$homepage protected_oe property

The website url, if any
protected $homepage

$id protected_oe property

protected $id

$indexedAt protected_oe property

Last indexing time.
protected $indexedAt

$isFork protected_oe property

True if the Repo is a fork
protected $isFork

$keywords protected_oe property

Bundle keywords
protected Collection,Doctrine\Common\Collections $keywords
Résultat Doctrine\Common\Collections\Collection

$lastCheckAt protected_oe property

Date of the last successful GitHub check
protected $lastCheckAt

$lastCommitAt protected_oe property

Date of the last Git commit
protected $lastCommitAt

$lastTweetedAt protected_oe property

Date when bundle was tweeted from knplabs account.
protected $lastTweetedAt

$license protected_oe property

The bundle license text extracted from source code
protected $license

$licenseType protected_oe property

The bundle license type extracted from composer.json
protected $licenseType

$name protected_oe property

Repo name, e.g. "MarkdownBundle" Like in GitHub, this name is not unique
protected $name

$nbFavorers protected_oe property

protected $nbFavorers

$nbFollowers protected_oe property

Number of GitHub followers
protected $nbFollowers

$nbForks protected_oe property

Number of GitHub forks
protected $nbForks

$nbRecommenders protected_oe property

protected $nbRecommenders

$owner protected_oe property

Owner of the bundle
protected Collection,Doctrine\Common\Collections $owner
Résultat Doctrine\Common\Collections\Collection

$ownerName protected_oe property

The name of the owner who owns this bundle This value is redundant with the name of the referenced Owner, for performance reasons
protected $ownerName

$ownerType protected_oe property

The type of the owner who owns this bundle This value is redundant with the class of the referenced Owner, for performance reasons
protected $ownerType

$readme protected_oe property

The bundle readme text extracted from source code
protected $readme

$recommenders protected_oe property

Developers recommending the bundle
protected Collection,Doctrine\Common\Collections $recommenders
Résultat Doctrine\Common\Collections\Collection

$score protected_oe property

Internal score of the Repo, based on several indicators Defines the Repo position in lists and searches
protected $score

$scoreDetails protected_oe property

Latest score's details
protected array $scoreDetails
Résultat array

$scores protected_oe property

Internal scores
protected Collection,Doctrine\Common\Collections $scores
Résultat Doctrine\Common\Collections\Collection

$state protected_oe property

Status of bundle
protected $state

$travisCiBuildStatus protected_oe property

Travis Ci last build status
protected $travisCiBuildStatus

$trend1 protected_oe property

Trend over the last day. Max is better.
protected $trend1

$updatedAt protected_oe property

Repo update date (on this website)
protected $updatedAt

$usesTravisCi protected_oe property

True if the Repo uses Travis CI
protected $usesTravisCi

$versionsHistory protected_oe property

Bundle versions history
protected $versionsHistory