merged 2.0
This commit is contained in:
commit
ca8dc87940
@ -7,6 +7,15 @@ in 2.0 minor versions.
|
||||
To get the diff for a specific change, go to https://github.com/symfony/symfony/commit/XXX where XXX is the change hash
|
||||
To get the diff between two versions, go to https://github.com/symfony/symfony/compare/v2.0.0...v2.0.1
|
||||
|
||||
* 2.0.9 (2012-01-06)
|
||||
|
||||
* 0492290: [Console] added a missing method (closes #3043)
|
||||
* e09b523: updated Twig to 1.5.1 to fix a regression
|
||||
* 261325d: Cast $query['params'] to array to ensure it is a valid argument for the foreach.
|
||||
* 85ca8e3: ParameterBag no longer resolves parameters that have spaces.
|
||||
* aacb2de: use the forward compat version in the Filesystem service
|
||||
* 41950a6: [WebProfilerBundle] add margin-bottom to caption
|
||||
|
||||
* 2.0.8 (2011-12-26)
|
||||
|
||||
* adea589: [Twig] made code compatible with Twig 1.5
|
||||
|
120
CONTRIBUTORS.md
120
CONTRIBUTORS.md
@ -8,98 +8,103 @@ Symfony2 is the result of the work of many people who made the code better
|
||||
- Bernhard Schussek (bschussek)
|
||||
- Johannes (schmittjoh)
|
||||
- Jordi Boggiano (Seldaek)
|
||||
- Kris Wallsmith (kriswallsmith)
|
||||
- Christophe Coevoet (stof)
|
||||
- Lukas Kahwe Smith (lsmith77)
|
||||
- Victor Berchet (vicb)
|
||||
- Kris Wallsmith (kriswallsmith)
|
||||
- Alexandre Salomé (alexandresalome)
|
||||
- Victor Berchet (vicb)
|
||||
- Benjamin Eberlei (beberlei)
|
||||
- Joseph Bielawski (stloyd)
|
||||
- stealth35 (stealth35)
|
||||
- Ryan Weaver (weaverryan)
|
||||
- Pascal Borreli (pborreli)
|
||||
- Joseph Bielawski (stloyd)
|
||||
- Eric Clemmons (ericclemmons)
|
||||
- Jeremy Mikola (jmikola)
|
||||
- Henrik Westphal (snc)
|
||||
- Igor Wiedler (igorw)
|
||||
- Ryan Weaver (weaverryan)
|
||||
- Pascal Borreli (pborreli)
|
||||
- Drak (drak)
|
||||
- Tigran Azatyan (tigranazatyan)
|
||||
- Jordan Alliot (jalliot)
|
||||
- Igor Wiedler (igorw)
|
||||
- Hugo Hamon (hhamon)
|
||||
- Miha Vrhovnik (mvrhov)
|
||||
- Arnout Boks (aboks)
|
||||
- Jonathan H. Wage (jwage)
|
||||
- Benjamin Dulau (benjamindulau)
|
||||
- Martin Hasoň (hason)
|
||||
- Thibault Duplessis (ornicar)
|
||||
- Helmer Aaviksoo (helmer)
|
||||
- Excel Web Zone (excelwebzone)
|
||||
- Helmer Aaviksoo (helmer)
|
||||
- Jonathan H. Wage (jwage)
|
||||
- Martin Hasoň (hason)
|
||||
- Jacob Dreesen (jdreesen)
|
||||
- Bulat Shakirzyanov (avalanche123)
|
||||
- Eriksen Costa (eriksencosta)
|
||||
- Francis Besset (francisbesset)
|
||||
- Richard Shank (IamPersistent)
|
||||
- Thibault Duplessis (ornicar)
|
||||
- Wotre (Wotre)
|
||||
- dbu
|
||||
- Henrik Bjørnskov (henrikbjorn)
|
||||
- Richard Shank (IamPersistent)
|
||||
- Bulat Shakirzyanov (avalanche123)
|
||||
- Francis Besset (francisbesset)
|
||||
- Eriksen Costa (eriksencosta)
|
||||
- William DURAND (willdurand)
|
||||
- yethee (yethee)
|
||||
- Lenar Lõhmus (lenar)
|
||||
- Richard Miller (richardmiller)
|
||||
- Dariusz Górecki (canni)
|
||||
- Konstantin Kudryashov (everzet)
|
||||
- Lenar Lõhmus (lenar)
|
||||
- Henrik Bjørnskov (henrikbjorn)
|
||||
- Richard Miller (richardmiller)
|
||||
- brki (brki)
|
||||
- Brikou CARRE (brikou)
|
||||
- Daniel Holmes (danielholmes)
|
||||
- William DURAND (willdurand)
|
||||
- Konstantin Kudryashov (everzet)
|
||||
- Brandon Turner (blt04)
|
||||
- brki (brki)
|
||||
- Hidenori Goto (hidenorigoto)
|
||||
- John Wards (johnwards)
|
||||
- Antoine Hérault (Herzult)
|
||||
- Danny Berger (dpb587)
|
||||
- Hidenori Goto (hidenorigoto)
|
||||
- Alif Rachmawadi (alifity)
|
||||
- Fabien Pennequin (FabienPennequin)
|
||||
- Tobias Schultze (Tobion)
|
||||
- Marc Weistroff (marcw)
|
||||
- John Wards (johnwards)
|
||||
- Julien Brochet (aerialls)
|
||||
- Michel Salib (michelsalib)
|
||||
- Marcin Chylek (SongoQ)
|
||||
- Christian Raue (craue)
|
||||
- superjavason (superjavason)
|
||||
- Thomas (rande)
|
||||
- Tobias Schultze (Tobion)
|
||||
- Antoine Hérault (Herzult)
|
||||
- Joseph Rouff (rouffj)
|
||||
- Katsuhiro OGAWA (fivestar)
|
||||
- blue-eyes (blue-eyes)
|
||||
- superjavason (superjavason)
|
||||
- Fabien Pennequin (FabienPennequin)
|
||||
- Christian Raue (craue)
|
||||
- Marc Weistroff (marcw)
|
||||
- flevour (flevour)
|
||||
- Thomas (rande)
|
||||
- Bart van den Burg (Burgov)
|
||||
- Oscar Cubo Medina (ocubom)
|
||||
- Pierre Minnieur (pminnieur)
|
||||
- Daniel Gomes (danielcsgomes)
|
||||
- Miquel Rodríguez Telep (mrtorrent)
|
||||
- flevour (flevour)
|
||||
- Katsuhiro OGAWA (fivestar)
|
||||
- blue-eyes (blue-eyes)
|
||||
- Michele Orselli (micheleorselli)
|
||||
- Javier Eguiluz (javiereguiluz)
|
||||
- Bernd Matzner (bmatzner)
|
||||
- Tim Nagel (merk)
|
||||
- Robert Schönthal (digitalkaoz)
|
||||
- Michel Weimerskirch (mweimerskirch)
|
||||
- Michele Orselli (micheleorselli)
|
||||
- Jakub Zalas (jakzal)
|
||||
- Matthieu Vachon (maoueh)
|
||||
- Amal Raghav (kertz)
|
||||
- Artur Kotyrba (udat)
|
||||
- Bernd Matzner (bmatzner)
|
||||
- Clément JOBEILI (dator)
|
||||
- Tom Klingenberg (ktomk)
|
||||
- Thomas Bibb (thomasbibb)
|
||||
- Marek Kalnik (marekkalnik)
|
||||
- Oscar Cubo Medina (ocubom)
|
||||
- xaav
|
||||
- Pierre Minnieur (pminnieur)
|
||||
- Neil Katin
|
||||
- Noel GUILBERT (noelg)
|
||||
- Jakub Zalas (jakzal)
|
||||
- Matthieu Vachon (maoueh)
|
||||
- Klein Florian (docteurklein)
|
||||
- Martin Schuhfuss (usefulthink)
|
||||
- Amal Raghav (kertz)
|
||||
- Artur Kotyrba (udat)
|
||||
- stloyd
|
||||
- Dennis Benkert (denderello)
|
||||
- Bart van den Burg (Burgov)
|
||||
- Matthieu Bontemps (mbontemps)
|
||||
- Kirill chEbba Chebunin (chEbba)
|
||||
- John Carr (Jc2k)
|
||||
- jdewit (jdewit)
|
||||
- Teo (teo-sk)
|
||||
- Clément JOBEILI (dator)
|
||||
- Dustin Dobervich (dustin10)
|
||||
- Noel GUILBERT (noelg)
|
||||
- andrewtch (andrewtch)
|
||||
- Thomas Adam (tecbot)
|
||||
- Martin Schuhfuss (usefulthink)
|
||||
- Dennis Benkert (denderello)
|
||||
- Matthieu Bontemps (mbontemps)
|
||||
- Robert Gruendler (pulse00)
|
||||
- Dustin Whittle (dustinwhittle)
|
||||
- Jean-François PHILIPPE (jfphilippe)
|
||||
- Justin Hileman (bobthecow)
|
||||
@ -114,14 +119,14 @@ Symfony2 is the result of the work of many people who made the code better
|
||||
- Xavier Montaña (xmontana)
|
||||
- Arjen Brouwer (arjenjb)
|
||||
- Boussekeyt Jules (gordonslondon)
|
||||
- Thomas Adam (tecbot)
|
||||
- Jan Sorgalla (jsor)
|
||||
- Grégoire Paris (greg0ire)
|
||||
- Douglas Greenshields (shieldo)
|
||||
- Lee McDermott (lmcd)
|
||||
- Shein Alexey (conf)
|
||||
- Manuel de Ruiter (ManuelAC)
|
||||
- Jeroen Hoek (jdhoek)
|
||||
- Robert Gruendler (pulse00)
|
||||
- Xavier HAUSHERR (xkobal)
|
||||
- geoffrey
|
||||
- Matthew Lewinski (lewinski)
|
||||
- dlsniper (dlsniper)
|
||||
@ -133,25 +138,23 @@ Symfony2 is the result of the work of many people who made the code better
|
||||
- Aurelijus Valeiša (aurelijus)
|
||||
- Ray (rrehbeindoi)
|
||||
- Adrian Rudnik (kreischweide)
|
||||
- Dustin Dobervich (dustin10)
|
||||
- Kevin Bond (kbond)
|
||||
- Andréia Bohner (andreia)
|
||||
- Yuen-Chi Lian (yclian)
|
||||
- Greg Thornton (xdissent)
|
||||
- andrewtch (andrewtch)
|
||||
- Konstantin Leboev (realmfoo)
|
||||
- Grégoire Paris (greg0ire)
|
||||
- Donald Tyler (Chekote)
|
||||
- Kai
|
||||
- Gyula Sallai (thesalla)
|
||||
- Sergey Linnik (Partugal)
|
||||
- Laszlo Korte (laszlokorte)
|
||||
- Jonathan Ingram (jonathaningram)
|
||||
- Julien DIDIER (juliendidier)
|
||||
- Hubert LECORCHE (hlecorche)
|
||||
- Michael Ridgway (mridgway)
|
||||
- Stepan Tanasiychuk (stfalcon)
|
||||
- Bertrand Zuchuat (Garfield-fr)
|
||||
- Adam Monsen (meonkeys)
|
||||
- Xavier HAUSHERR (xkobal)
|
||||
- Jan Schumann (janschumann)
|
||||
- Vadim Tyukov (vatson)
|
||||
- Asier Illarramendi (doup)
|
||||
@ -171,6 +174,7 @@ Symfony2 is the result of the work of many people who made the code better
|
||||
- Steven Surowiec (steves)
|
||||
- arnaud-lb (arnaud-lb)
|
||||
- Ivan Rey (ivanrey)
|
||||
- Matthias (mpdude)
|
||||
- Ned Schwartz (theinterned)
|
||||
- Gordon Franke (gimler)
|
||||
- Aurélien Fredouelle (AurelC2G)
|
||||
@ -178,14 +182,12 @@ Symfony2 is the result of the work of many people who made the code better
|
||||
- Geoffrey Tran (geoffreytran)
|
||||
- Christian Schaefer (caefer)
|
||||
- Elliot Anderson (elliot)
|
||||
- Kevin Bond (kbond)
|
||||
- José Nahuel Cuesta Luengo (ncuesta)
|
||||
- Sebastian Marek (proofek)
|
||||
- erheme318 (erheme318)
|
||||
- Michael Holm (hollodk)
|
||||
- Rostyslav Kinash
|
||||
- yktd26 (yktd26)
|
||||
- Javier Eguiluz (javiereguiluz)
|
||||
- umpirski (umpirski)
|
||||
- Sebastian Bergmann (sebastianbergmann)
|
||||
- Hossein Bukhamsin (husinluck)
|
||||
@ -196,6 +198,7 @@ Symfony2 is the result of the work of many people who made the code better
|
||||
- markchalloner (markchalloner)
|
||||
- Michael Williams (mtotheikle)
|
||||
- Casper Valdemar Poulsen
|
||||
- franmomu (franmomu)
|
||||
- pscheit (pscheit)
|
||||
- Degory Valentine
|
||||
- Krzysiek Łabuś (Crozin)
|
||||
@ -210,7 +213,6 @@ Symfony2 is the result of the work of many people who made the code better
|
||||
- Cyril Quintin (cyqui)
|
||||
- kazusuke sasezaki (sasezaki)
|
||||
- cim-dch (cim-dch)
|
||||
- Julien DIDIER (juliendidier)
|
||||
- Chris Smith (cs278)
|
||||
- Derek ROTH (DerekRoth)
|
||||
- mwsaz
|
||||
@ -222,13 +224,16 @@ Symfony2 is the result of the work of many people who made the code better
|
||||
- Arno Geurts
|
||||
- ds (dantleech)
|
||||
- Daniel Cestari (dcestari)
|
||||
- Javier López (loalf)
|
||||
- Magnus Nordlander (magnusnordlander)
|
||||
- Pavel Campr (pcampr)
|
||||
- Markus Tacker (tacker)
|
||||
- Benoît Merlet (trompette)
|
||||
- Jan Behrens (deegital)
|
||||
- Michael (mshtukin)
|
||||
- sensio
|
||||
- Théophile Helleboid - chtitux (chtitux)
|
||||
- Olivier Dolbeau (odolbeau)
|
||||
- irmantas (irmantas)
|
||||
- tero (tero)
|
||||
- Stainslav Turza (S0RIEN)
|
||||
@ -267,6 +272,7 @@ Symfony2 is the result of the work of many people who made the code better
|
||||
- Benjamin Lévêque (benji07)
|
||||
- Sebastian Hörl (blogsh)
|
||||
- Benjamin Zikarsky (bzikarsky)
|
||||
- alefranz (alefranz)
|
||||
- Andy Stanberry (cranberyxl)
|
||||
- Gerard van Helden (drm)
|
||||
- Alessio (ioalessio)
|
||||
@ -306,6 +312,7 @@ Symfony2 is the result of the work of many people who made the code better
|
||||
- Adán Lobato (adanlobato)
|
||||
- chesteroni (chesteroni)
|
||||
- Elnur Abdurrakhimov (elnur)
|
||||
- Toni Uebernickel (havvg)
|
||||
- Beau Simensen (simensen)
|
||||
- Juan Ases García (Ases)
|
||||
- FabienD (FabienD)
|
||||
@ -327,10 +334,12 @@ Symfony2 is the result of the work of many people who made the code better
|
||||
- dorkitude (dorkitude)
|
||||
- Kousuke Ebihara (ebihara)
|
||||
- Vladislav (ideea)
|
||||
- Matt Robinson (inanimatt)
|
||||
- Abdulkadir N. A. (kadeer)
|
||||
- Krzysztof Menżyk (krymen)
|
||||
- kwiateusz (kwiateusz)
|
||||
- Samuel Laulhau (lalop)
|
||||
- Peter Kokot (maastermedia)
|
||||
- Penny Leach (mjollnir)
|
||||
- Michael Schneider (mschneid)
|
||||
- Drew Butler (nodrew)
|
||||
@ -340,6 +349,7 @@ Symfony2 is the result of the work of many people who made the code better
|
||||
- pzwosta (pzwosta)
|
||||
- Ruud Kamphuis (ruudk)
|
||||
- Matt Fitzgerald (tirnanog06)
|
||||
- Tyler Stroud (tystr)
|
||||
- Vyacheslav Slinko (vslinko)
|
||||
- Josiah (web-dev)
|
||||
- Gustavo Adrian
|
||||
|
@ -36,7 +36,7 @@ class AssetsInstallCommand extends ContainerAwareCommand
|
||||
))
|
||||
->addOption('symlink', null, InputOption::VALUE_NONE, 'Symlinks the assets instead of copying it')
|
||||
->addOption('relative', null, InputOption::VALUE_NONE, 'Make relative symlinks')
|
||||
->setDescription('Install bundles web assets under a public web directory')
|
||||
->setDescription('Installs bundles web assets under a public web directory')
|
||||
->setHelp(<<<EOT
|
||||
The <info>assets:install</info> command installs bundle assets into a given
|
||||
directory (e.g. the web directory).
|
||||
|
@ -37,7 +37,7 @@ class CacheClearCommand extends ContainerAwareCommand
|
||||
->setDefinition(array(
|
||||
new InputOption('no-warmup', '', InputOption::VALUE_NONE, 'Do not warm up the cache'),
|
||||
))
|
||||
->setDescription('Clear the cache')
|
||||
->setDescription('Clears the cache')
|
||||
->setHelp(<<<EOF
|
||||
The <info>cache:clear</info> command clears the application cache for a given environment
|
||||
and debug mode:
|
||||
|
@ -119,13 +119,53 @@
|
||||
<target>Naložena datoteka je prevelika. Prosim, poizkusite naložiti manjšo</target>
|
||||
</trans-unit>
|
||||
<trans-unit id="30">
|
||||
<source>The CSRF token is invalid</source>
|
||||
<target>CSRF vrednost je napačna</target>
|
||||
<source>The CSRF token is invalid. Please try to resubmit the form</source>
|
||||
<target>CSRF vrednost je napačna. Prosimo, ponovno pošljite obrazec</target>
|
||||
</trans-unit>
|
||||
<trans-unit id="31">
|
||||
<source>The two values should be equal</source>
|
||||
<target>Vrednosti morata biti enaki</target>
|
||||
</trans-unit>
|
||||
<trans-unit id="32">
|
||||
<source>The file is too large. Allowed maximum size is {{ limit }}</source>
|
||||
<target>Datoteka je prevelika. Največja dovoljena velikost je {{ limit }}</target>
|
||||
</trans-unit>
|
||||
<trans-unit id="33">
|
||||
<source>The file is too large</source>
|
||||
<target>Datoteka je prevelika</target>
|
||||
</trans-unit>
|
||||
<trans-unit id="34">
|
||||
<source>The file could not be uploaded</source>
|
||||
<target>Datoteke ni bilo mogoče naložiti</target>
|
||||
</trans-unit>
|
||||
<trans-unit id="35">
|
||||
<source>This value should be a valid number</source>
|
||||
<target>Vrednost mora biti veljavna številka</target>
|
||||
</trans-unit>
|
||||
<trans-unit id="36">
|
||||
<source>This file is not a valid image</source>
|
||||
<target>Datoteka ni veljavna slika</target>
|
||||
</trans-unit>
|
||||
<trans-unit id="37">
|
||||
<source>This is not a valid IP address</source>
|
||||
<target>IP naslov ni veljaven</target>
|
||||
</trans-unit>
|
||||
<trans-unit id="38">
|
||||
<source>This value is not a valid language</source>
|
||||
<target>Vrednost ni veljaven jezik</target>
|
||||
</trans-unit>
|
||||
<trans-unit id="39">
|
||||
<source>This value is not a valid locale</source>
|
||||
<target>Vrednost ni veljavna lokalnost</target>
|
||||
</trans-unit>
|
||||
<trans-unit id="40">
|
||||
<source>This value is not a valid country</source>
|
||||
<target>Vrednost ni veljavna država</target>
|
||||
</trans-unit>
|
||||
<trans-unit id="41">
|
||||
<source>This value is already used</source>
|
||||
<target>Ta vrednost je že uporabljena</target>
|
||||
</trans-unit>
|
||||
</body>
|
||||
</file>
|
||||
</xliff>
|
||||
|
@ -23,7 +23,7 @@
|
||||
"symfony/filesystem": "self.version",
|
||||
"symfony/routing": "self.version",
|
||||
"symfony/templating": "self.version",
|
||||
"symfony/translator": "self.version",
|
||||
"symfony/translation": "self.version",
|
||||
"doctrine/common": ">=2.1,<2.3-dev"
|
||||
},
|
||||
"recommend": {
|
||||
|
@ -31,7 +31,7 @@ class SendEmailCommand extends ContainerAwareCommand
|
||||
{
|
||||
$this
|
||||
->setName('swiftmailer:spool:send')
|
||||
->setDescription('Send emails from the spool')
|
||||
->setDescription('Sends emails from the spool')
|
||||
->addOption('message-limit', 0, InputOption::VALUE_OPTIONAL, 'The maximum number of messages to send.')
|
||||
->addOption('time-limit', 0, InputOption::VALUE_OPTIONAL, 'The time limit for sending messages (in seconds).')
|
||||
->setHelp(<<<EOF
|
||||
|
@ -670,7 +670,7 @@ class Application
|
||||
}
|
||||
}
|
||||
|
||||
return implode("\n", $messages);
|
||||
return implode(PHP_EOL, $messages);
|
||||
}
|
||||
|
||||
/**
|
||||
@ -798,7 +798,8 @@ class Application
|
||||
|
||||
if (null !== $this->runningCommand) {
|
||||
$output->writeln(sprintf('<info>%s</info>', sprintf($this->runningCommand->getSynopsis(), $this->getName())));
|
||||
$output->writeln("\n");
|
||||
$output->writeln("");
|
||||
$output->writeln("");
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -67,6 +67,16 @@ class Command
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Ignores validation errors.
|
||||
*
|
||||
* This is mainly useful for the help command.
|
||||
*/
|
||||
public function ignoreValidationErrors()
|
||||
{
|
||||
$this->ignoreValidationErrors = true;
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets the application instance for this command.
|
||||
*
|
||||
|
@ -32,7 +32,7 @@ class HelpCommand extends Command
|
||||
*/
|
||||
protected function configure()
|
||||
{
|
||||
$this->ignoreValidationErrors = true;
|
||||
$this->ignoreValidationErrors();
|
||||
|
||||
$this
|
||||
->setDefinition(array(
|
||||
|
@ -653,6 +653,8 @@ EOF;
|
||||
*/
|
||||
private function addConstructor()
|
||||
{
|
||||
$arguments = $this->container->getParameterBag()->all() ? 'new ParameterBag($this->getDefaultParameters())' : null;
|
||||
|
||||
$code = <<<EOF
|
||||
|
||||
/**
|
||||
@ -660,7 +662,7 @@ EOF;
|
||||
*/
|
||||
public function __construct()
|
||||
{
|
||||
parent::__construct(new ParameterBag(\$this->getDefaultParameters()));
|
||||
parent::__construct($arguments);
|
||||
|
||||
EOF;
|
||||
|
||||
|
@ -744,7 +744,7 @@ class Request
|
||||
* It builds a normalized query string, where keys/value pairs are alphabetized
|
||||
* and have consistent escaping.
|
||||
*
|
||||
* @return string A normalized query string for the Request
|
||||
* @return string|null A normalized query string for the Request
|
||||
*
|
||||
* @api
|
||||
*/
|
||||
@ -1054,7 +1054,7 @@ class Request
|
||||
*
|
||||
* @param array $locales An array of ordered available locales
|
||||
*
|
||||
* @return string The preferred locale
|
||||
* @return string|null The preferred locale
|
||||
*
|
||||
* @api
|
||||
*/
|
||||
@ -1062,7 +1062,7 @@ class Request
|
||||
{
|
||||
$preferredLanguages = $this->getLanguages();
|
||||
|
||||
if (null === $locales) {
|
||||
if (empty($locales)) {
|
||||
return isset($preferredLanguages[0]) ? $preferredLanguages[0] : null;
|
||||
}
|
||||
|
||||
@ -1168,6 +1168,8 @@ class Request
|
||||
* Splits an Accept-* HTTP header.
|
||||
*
|
||||
* @param string $header Header to split
|
||||
*
|
||||
* @return array Array indexed by the values of the Accept-* header in preferred order
|
||||
*/
|
||||
public function splitHttpAcceptHeader($header)
|
||||
{
|
||||
|
@ -245,7 +245,7 @@ class Response
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets the response content
|
||||
* Sets the response content.
|
||||
*
|
||||
* Valid types are strings, numbers, and objects that implement a __toString() method.
|
||||
*
|
||||
@ -263,7 +263,7 @@ class Response
|
||||
}
|
||||
|
||||
/**
|
||||
* Gets the current response content
|
||||
* Gets the current response content.
|
||||
*
|
||||
* @return string Content
|
||||
*
|
||||
@ -299,7 +299,7 @@ class Response
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets response status code.
|
||||
* Sets the response status code.
|
||||
*
|
||||
* @param integer $code HTTP status code
|
||||
* @param string $text HTTP status text
|
||||
@ -319,7 +319,7 @@ class Response
|
||||
}
|
||||
|
||||
/**
|
||||
* Retrieves status code for the current web response.
|
||||
* Retrieves the status code for the current web response.
|
||||
*
|
||||
* @return string Status code
|
||||
*
|
||||
@ -331,7 +331,7 @@ class Response
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets response charset.
|
||||
* Sets the response charset.
|
||||
*
|
||||
* @param string $charset Character set
|
||||
*
|
||||
@ -457,7 +457,7 @@ class Response
|
||||
*
|
||||
* @return \DateTime A \DateTime instance
|
||||
*
|
||||
* @throws \RuntimeException when the header is not parseable
|
||||
* @throws \RuntimeException When the header is not parseable
|
||||
*
|
||||
* @api
|
||||
*/
|
||||
@ -518,7 +518,7 @@ class Response
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets the Expires HTTP header with a \DateTime instance.
|
||||
* Sets the Expires HTTP header with a DateTime instance.
|
||||
*
|
||||
* If passed a null value, it removes the header.
|
||||
*
|
||||
@ -570,7 +570,7 @@ class Response
|
||||
*
|
||||
* This methods sets the Cache-Control max-age directive.
|
||||
*
|
||||
* @param integer $value A number of seconds
|
||||
* @param integer $value Number of seconds
|
||||
*
|
||||
* @api
|
||||
*/
|
||||
@ -584,7 +584,7 @@ class Response
|
||||
*
|
||||
* This methods sets the Cache-Control s-maxage directive.
|
||||
*
|
||||
* @param integer $value A number of seconds
|
||||
* @param integer $value Number of seconds
|
||||
*
|
||||
* @api
|
||||
*/
|
||||
@ -620,7 +620,7 @@ class Response
|
||||
*
|
||||
* This method adjusts the Cache-Control/s-maxage directive.
|
||||
*
|
||||
* @param integer $seconds The number of seconds
|
||||
* @param integer $seconds Number of seconds
|
||||
*
|
||||
* @api
|
||||
*/
|
||||
@ -634,7 +634,7 @@ class Response
|
||||
*
|
||||
* This method adjusts the Cache-Control/max-age directive.
|
||||
*
|
||||
* @param integer $seconds The number of seconds
|
||||
* @param integer $seconds Number of seconds
|
||||
*
|
||||
* @api
|
||||
*/
|
||||
@ -656,7 +656,7 @@ class Response
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets the Last-Modified HTTP header with a \DateTime instance.
|
||||
* Sets the Last-Modified HTTP header with a DateTime instance.
|
||||
*
|
||||
* If passed a null value, it removes the header.
|
||||
*
|
||||
@ -676,7 +676,7 @@ class Response
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the literal value of ETag HTTP header.
|
||||
* Returns the literal value of the ETag HTTP header.
|
||||
*
|
||||
* @return string The ETag HTTP header
|
||||
*
|
||||
@ -709,7 +709,7 @@ class Response
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets Response cache headers (validation and/or expiration).
|
||||
* Sets the response's cache headers (validation and/or expiration).
|
||||
*
|
||||
* Available options are: etag, last_modified, max_age, s_maxage, private, and public.
|
||||
*
|
||||
@ -819,15 +819,15 @@ class Response
|
||||
}
|
||||
|
||||
/**
|
||||
* Determines if the Response validators (ETag, Last-Modified) matches
|
||||
* Determines if the Response validators (ETag, Last-Modified) match
|
||||
* a conditional value specified in the Request.
|
||||
*
|
||||
* If the Response is not modified, it sets the status code to 304 and
|
||||
* remove the actual content by calling the setNotModified() method.
|
||||
* removes the actual content by calling the setNotModified() method.
|
||||
*
|
||||
* @param Request $request A Request instance
|
||||
*
|
||||
* @return Boolean true if the Response validators matches the Request, false otherwise
|
||||
* @return Boolean true if the Response validators match the Request, false otherwise
|
||||
*
|
||||
* @api
|
||||
*/
|
||||
|
@ -227,8 +227,8 @@ class ApplicationTest extends \PHPUnit_Framework_TestCase
|
||||
{
|
||||
$application = new Application();
|
||||
$application->add(new \FooCommand);
|
||||
$this->assertStringEqualsFile(self::$fixturesPath.'/application_astext1.txt', $application->asText(), '->asText() returns a text representation of the application');
|
||||
$this->assertStringEqualsFile(self::$fixturesPath.'/application_astext2.txt', $application->asText('foo'), '->asText() returns a text representation of the application');
|
||||
$this->assertStringEqualsFile(self::$fixturesPath.'/application_astext1.txt', str_replace(PHP_EOL, "\n", $application->asText()), '->asText() returns a text representation of the application');
|
||||
$this->assertStringEqualsFile(self::$fixturesPath.'/application_astext2.txt', str_replace(PHP_EOL, "\n", $application->asText('foo')), '->asText() returns a text representation of the application');
|
||||
}
|
||||
|
||||
public function testAsXml()
|
||||
|
@ -23,6 +23,6 @@ class Container extends AbstractContainer
|
||||
*/
|
||||
public function __construct()
|
||||
{
|
||||
parent::__construct(new ParameterBag($this->getDefaultParameters()));
|
||||
parent::__construct();
|
||||
}
|
||||
}
|
||||
|
@ -23,6 +23,6 @@ class ProjectServiceContainer extends Container
|
||||
*/
|
||||
public function __construct()
|
||||
{
|
||||
parent::__construct(new ParameterBag($this->getDefaultParameters()));
|
||||
parent::__construct();
|
||||
}
|
||||
}
|
||||
|
@ -737,7 +737,8 @@ class RequestTest extends \PHPUnit_Framework_TestCase
|
||||
public function testGetPreferredLanguage()
|
||||
{
|
||||
$request = new Request();
|
||||
$this->assertEquals('', $request->getPreferredLanguage());
|
||||
$this->assertNull($request->getPreferredLanguage());
|
||||
$this->assertNull($request->getPreferredLanguage(array()));
|
||||
$this->assertEquals('fr', $request->getPreferredLanguage(array('fr')));
|
||||
$this->assertEquals('fr', $request->getPreferredLanguage(array('fr', 'en')));
|
||||
$this->assertEquals('en', $request->getPreferredLanguage(array('en', 'fr')));
|
||||
|
Reference in New Issue
Block a user