text:
<!DOCTYPE html>

    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <title>Coq bench</title>
    <link rel="shortcut icon" type="image/png" href="../../../../../favicon.png" />
    <link href="../../../../../bootstrap.min.css" rel="stylesheet">
    <link href="//maxcdn.bootstrapcdn.com/font-awesome/4.2.0/css/font-awesome.min.css" rel="stylesheet">

            <button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#navbar" aria-expanded="false" aria-controls="navbar">
              Toggle navigation

            </button>
             Coq bench

Unstable

8.4.dev / contrib:ruler-compass-geometry 8.4.dev

2014-12-12 08:42:09

About

            « Up

              contrib:ruler-compass-geometry

                8.4.dev
                41 s

 (2014-12-12 08:42:09 UTC)

Lint

Command

ruby lint.rb unstable ../unstable/packages/coq:contrib:ruler-compass-geometry/coq:contrib:ruler-compass-geometry.8.4.dev

Return code

0

Duration

0 s

Output

The package is valid.

Dry install

Dry install with the current Coq version:

Command

opam install -y --dry-run coq:contrib:ruler-compass-geometry.8.4.dev coq.8.4.dev

Return code

0

Duration

1 s

Output

[NOTE] Package coq is already installed (current version is 8.4.dev).
The following actions will be performed:
 - install   coq:contrib:ruler-compass-geometry.8.4.dev
=== 1 to install ===
=-=- Synchronizing package archives -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
=-=- Installing packages =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
Building coq:contrib:ruler-compass-geometry.8.4.dev:
  coq_makefile -f Make -o Makefile
  make -j4
  make install
Installing coq:contrib:ruler-compass-geometry.8.4.dev.

Dry install without Coq, to test if the problem was incompatibility with the current Coq version:

Command

true

Return code

0

Duration

0 s

Install dependencies

Command

opam install -y --deps-only coq:contrib:ruler-compass-geometry.8.4.dev

Return code

0

Duration

2 s

Install

Command

opam install -y --verbose coq:contrib:ruler-compass-geometry.8.4.dev

Return code

0

Duration

41 s

Output

The following actions will be performed:
 - install   coq:contrib:ruler-compass-geometry.8.4.dev
=== 1 to install ===
=-=- Synchronizing package archives -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
[coq:contrib:ruler-compass-geometry] Fetching https://gforge.inria.fr/git/coq-contribs/ruler-compass-geometry.git#v8.4
Initialized empty Git repository in /home/bench/.opam/packages.dev/coq:contrib:ruler-compass-geometry.8.4.dev/.git/
[master (root-commit) 1d34770] opam-git-init
From https://gforge.inria.fr/git/coq-contribs/ruler-compass-geometry
 * [new branch]      v8.4       -> opam-ref
 * [new branch]      v8.4       -> origin/v8.4
A1_Plan.v
A2_Orientation.v
A3_Metrique.v
A4_Droite.v
A5_Cercle.v
A6_Intersection.v
B10_Longueur_Prop.v
B11_Angle_prop.v
B12_Tacticques_base.v
B1_Confondu_Prop.v
B2_Orient_Prop.v
B3_Alignes_Prop.v
B4_Droite_Def.v
B5_Entre_Prel.v
B6_Cercle_Def.v
B7_Triangle_Equilateral.v
B8_Point_Def.v
B9_Inegalite_Triang.v
C10_Milieu.v
C11_Mediatrice.v
C12_Angles_Opposes.v
C13_Angles_Supplem.v
C14_Angle_Droit.v
C15_Parallelogramm.v
C1_DemiDroite_Prop.v
C2_Entre_Prop.v
C3_Triangles_Egaux.v
C4_Triangles_non_degeneres_egaux.v
C5_Droite_Prop.v
C6_Parallele_Prop.v
C7_DroitesSecantesProp.v
C8_DroitesConfondues.v
C9_Triangles_Emboites.v
D1_DistanceProp.v
D2_Axe.v
D3_Triangle_Prop.v
D4_CongruenceProp.v
D5_ParalleleConst.v
D6_SumAnglesProp.v
D7_NonParalleles_Secantes.v
E1_Incidence.v
E2_Ordre.v
E3_Congruence.v
E4_Continuite.v
E5_Parallelisme.v
Make
Makefile
bench.log
description
HEAD is now at 7f98886 Adapted contributions to new policy for automatic introduction of
=-=- Installing packages =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
Building coq:contrib:ruler-compass-geometry.8.4.dev:
  coq_makefile -f Make -o Makefile
  make -j4
  make install
"coqdep" -c -slash -R . RulerCompassGeometry "A1_Plan.v" > "A1_Plan.v.d" || ( RV=$?; rm -f "A1_Plan.v.d"; exit ${RV} )
"coqdep" -c -slash -R . RulerCompassGeometry "A2_Orientation.v" > "A2_Orientation.v.d" || ( RV=$?; rm -f "A2_Orientation.v.d"; exit ${RV} )
"coqdep" -c -slash -R . RulerCompassGeometry "A3_Metrique.v" > "A3_Metrique.v.d" || ( RV=$?; rm -f "A3_Metrique.v.d"; exit ${RV} )
"coqdep" -c -slash -R . RulerCompassGeometry "A4_Droite.v" > "A4_Droite.v.d" || ( RV=$?; rm -f "A4_Droite.v.d"; exit ${RV} )
"coqdep" -c -slash -R . RulerCompassGeometry "A5_Cercle.v" > "A5_Cercle.v.d" || ( RV=$?; rm -f "A5_Cercle.v.d"; exit ${RV} )
"coqdep" -c -slash -R . RulerCompassGeometry "A6_Intersection.v" > "A6_Intersection.v.d" || ( RV=$?; rm -f "A6_Intersection.v.d"; exit ${RV} )
"coqdep" -c -slash -R . RulerCompassGeometry "B10_Longueur_Prop.v" > "B10_Longueur_Prop.v.d" || ( RV=$?; rm -f "B10_Longueur_Prop.v.d"; exit ${RV} )
"coqdep" -c -slash -R . RulerCompassGeometry "B11_Angle_prop.v" > "B11_Angle_prop.v.d" || ( RV=$?; rm -f "B11_Angle_prop.v.d"; exit ${RV} )
"coqdep" -c -slash -R . RulerCompassGeometry "B12_Tacticques_base.v" > "B12_Tacticques_base.v.d" || ( RV=$?; rm -f "B12_Tacticques_base.v.d"; exit ${RV} )
"coqdep" -c -slash -R . RulerCompassGeometry "B1_Confondu_Prop.v" > "B1_Confondu_Prop.v.d" || ( RV=$?; rm -f "B1_Confondu_Prop.v.d"; exit ${RV} )
"coqdep" -c -slash -R . RulerCompassGeometry "B2_Orient_Prop.v" > "B2_Orient_Prop.v.d" || ( RV=$?; rm -f "B2_Orient_Prop.v.d"; exit ${RV} )
"coqdep" -c -slash -R . RulerCompassGeometry "B3_Alignes_Prop.v" > "B3_Alignes_Prop.v.d" || ( RV=$?; rm -f "B3_Alignes_Prop.v.d"; exit ${RV} )
"coqdep" -c -slash -R . RulerCompassGeometry "B4_Droite_Def.v" > "B4_Droite_Def.v.d" || ( RV=$?; rm -f "B4_Droite_Def.v.d"; exit ${RV} )
"coqdep" -c -slash -R . RulerCompassGeometry "B5_Entre_Prel.v" > "B5_Entre_Prel.v.d" || ( RV=$?; rm -f "B5_Entre_Prel.v.d"; exit ${RV} )
"coqdep" -c -slash -R . RulerCompassGeometry "B6_Cercle_Def.v" > "B6_Cercle_Def.v.d" || ( RV=$?; rm -f "B6_Cercle_Def.v.d"; exit ${RV} )
"coqdep" -c -slash -R . RulerCompassGeometry "B7_Triangle_Equilateral.v" > "B7_Triangle_Equilateral.v.d" || ( RV=$?; rm -f "B7_Triangle_Equilateral.v.d"; exit ${RV} )
"coqdep" -c -slash -R . RulerCompassGeometry "B8_Point_Def.v" > "B8_Point_Def.v.d" || ( RV=$?; rm -f "B8_Point_Def.v.d"; exit ${RV} )
"coqdep" -c -slash -R . RulerCompassGeometry "B9_Inegalite_Triang.v" > "B9_Inegalite_Triang.v.d" || ( RV=$?; rm -f "B9_Inegalite_Triang.v.d"; exit ${RV} )
"coqdep" -c -slash -R . RulerCompassGeometry "C10_Milieu.v" > "C10_Milieu.v.d" || ( RV=$?; rm -f "C10_Milieu.v.d"; exit ${RV} )
"coqdep" -c -slash -R . RulerCompassGeometry "C11_Mediatrice.v" > "C11_Mediatrice.v.d" || ( RV=$?; rm -f "C11_Mediatrice.v.d"; exit ${RV} )
"coqdep" -c -slash -R . RulerCompassGeometry "C12_Angles_Opposes.v" > "C12_Angles_Opposes.v.d" || ( RV=$?; rm -f "C12_Angles_Opposes.v.d"; exit ${RV} )
"coqdep" -c -slash -R . RulerCompassGeometry "C13_Angles_Supplem.v" > "C13_Angles_Supplem.v.d" || ( RV=$?; rm -f "C13_Angles_Supplem.v.d"; exit ${RV} )
"coqdep" -c -slash -R . RulerCompassGeometry "C14_Angle_Droit.v" > "C14_Angle_Droit.v.d" || ( RV=$?; rm -f "C14_Angle_Droit.v.d"; exit ${RV} )
"coqdep" -c -slash -R . RulerCompassGeometry "C15_Parallelogramm.v" > "C15_Parallelogramm.v.d" || ( RV=$?; rm -f "C15_Parallelogramm.v.d"; exit ${RV} )
"coqdep" -c -slash -R . RulerCompassGeometry "C1_DemiDroite_Prop.v" > "C1_DemiDroite_Prop.v.d" || ( RV=$?; rm -f "C1_DemiDroite_Prop.v.d"; exit ${RV} )
"coqdep" -c -slash -R . RulerCompassGeometry "C2_Entre_Prop.v" > "C2_Entre_Prop.v.d" || ( RV=$?; rm -f "C2_Entre_Prop.v.d"; exit ${RV} )
"coqdep" -c -slash -R . RulerCompassGeometry "C3_Triangles_Egaux.v" > "C3_Triangles_Egaux.v.d" || ( RV=$?; rm -f "C3_Triangles_Egaux.v.d"; exit ${RV} )
"coqdep" -c -slash -R . RulerCompassGeometry "C4_Triangles_non_degeneres_egaux.v" > "C4_Triangles_non_degeneres_egaux.v.d" || ( RV=$?; rm -f "C4_Triangles_non_degeneres_egaux.v.d"; exit ${RV} )
"coqdep" -c -slash -R . RulerCompassGeometry "C5_Droite_Prop.v" > "C5_Droite_Prop.v.d" || ( RV=$?; rm -f "C5_Droite_Prop.v.d"; exit ${RV} )
"coqdep" -c -slash -R . RulerCompassGeometry "C6_Parallele_Prop.v" > "C6_Parallele_Prop.v.d" || ( RV=$?; rm -f "C6_Parallele_Prop.v.d"; exit ${RV} )
"coqdep" -c -slash -R . RulerCompassGeometry "C7_DroitesSecantesProp.v" > "C7_DroitesSecantesProp.v.d" || ( RV=$?; rm -f "C7_DroitesSecantesProp.v.d"; exit ${RV} )
"coqdep" -c -slash -R . RulerCompassGeometry "C8_DroitesConfondues.v" > "C8_DroitesConfondues.v.d" || ( RV=$?; rm -f "C8_DroitesConfondues.v.d"; exit ${RV} )
"coqdep" -c -slash -R . RulerCompassGeometry "C9_Triangles_Emboites.v" > "C9_Triangles_Emboites.v.d" || ( RV=$?; rm -f "C9_Triangles_Emboites.v.d"; exit ${RV} )
"coqdep" -c -slash -R . RulerCompassGeometry "D1_DistanceProp.v" > "D1_DistanceProp.v.d" || ( RV=$?; rm -f "D1_DistanceProp.v.d"; exit ${RV} )
"coqdep" -c -slash -R . RulerCompassGeometry "D2_Axe.v" > "D2_Axe.v.d" || ( RV=$?; rm -f "D2_Axe.v.d"; exit ${RV} )
"coqdep" -c -slash -R . RulerCompassGeometry "D3_Triangle_Prop.v" > "D3_Triangle_Prop.v.d" || ( RV=$?; rm -f "D3_Triangle_Prop.v.d"; exit ${RV} )
"coqdep" -c -slash -R . RulerCompassGeometry "D4_CongruenceProp.v" > "D4_CongruenceProp.v.d" || ( RV=$?; rm -f "D4_CongruenceProp.v.d"; exit ${RV} )
"coqdep" -c -slash -R . RulerCompassGeometry "D5_ParalleleConst.v" > "D5_ParalleleConst.v.d" || ( RV=$?; rm -f "D5_ParalleleConst.v.d"; exit ${RV} )
"coqdep" -c -slash -R . RulerCompassGeometry "D6_SumAnglesProp.v" > "D6_SumAnglesProp.v.d" || ( RV=$?; rm -f "D6_SumAnglesProp.v.d"; exit ${RV} )
"coqdep" -c -slash -R . RulerCompassGeometry "D7_NonParalleles_Secantes.v" > "D7_NonParalleles_Secantes.v.d" || ( RV=$?; rm -f "D7_NonParalleles_Secantes.v.d"; exit ${RV} )
"coqdep" -c -slash -R . RulerCompassGeometry "E1_Incidence.v" > "E1_Incidence.v.d" || ( RV=$?; rm -f "E1_Incidence.v.d"; exit ${RV} )
"coqdep" -c -slash -R . RulerCompassGeometry "E2_Ordre.v" > "E2_Ordre.v.d" || ( RV=$?; rm -f "E2_Ordre.v.d"; exit ${RV} )
"coqdep" -c -slash -R . RulerCompassGeometry "E3_Congruence.v" > "E3_Congruence.v.d" || ( RV=$?; rm -f "E3_Congruence.v.d"; exit ${RV} )
"coqdep" -c -slash -R . RulerCompassGeometry "E4_Continuite.v" > "E4_Continuite.v.d" || ( RV=$?; rm -f "E4_Continuite.v.d"; exit ${RV} )
"coqdep" -c -slash -R . RulerCompassGeometry "E5_Parallelisme.v" > "E5_Parallelisme.v.d" || ( RV=$?; rm -f "E5_Parallelisme.v.d"; exit ${RV} )
"coqc"  -q  -R . RulerCompassGeometry   A1_Plan
"coqc"  -q  -R . RulerCompassGeometry   A2_Orientation
"coqc"  -q  -R . RulerCompassGeometry   A3_Metrique
"coqc"  -q  -R . RulerCompassGeometry   A4_Droite
"coqc"  -q  -R . RulerCompassGeometry   A5_Cercle
"coqc"  -q  -R . RulerCompassGeometry   A6_Intersection
"coqc"  -q  -R . RulerCompassGeometry   B1_Confondu_Prop
"coqc"  -q  -R . RulerCompassGeometry   B2_Orient_Prop
"coqc"  -q  -R . RulerCompassGeometry   B3_Alignes_Prop
"coqc"  -q  -R . RulerCompassGeometry   B4_Droite_Def
"coqc"  -q  -R . RulerCompassGeometry   B5_Entre_Prel
"coqc"  -q  -R . RulerCompassGeometry   B6_Cercle_Def
"coqc"  -q  -R . RulerCompassGeometry   B7_Triangle_Equilateral
"coqc"  -q  -R . RulerCompassGeometry   B8_Point_Def
"coqc"  -q  -R . RulerCompassGeometry   B9_Inegalite_Triang
"coqc"  -q  -R . RulerCompassGeometry   B10_Longueur_Prop
"coqc"  -q  -R . RulerCompassGeometry   B11_Angle_prop
"coqc"  -q  -R . RulerCompassGeometry   B12_Tacticques_base
"coqc"  -q  -R . RulerCompassGeometry   C1_DemiDroite_Prop
"coqc"  -q  -R . RulerCompassGeometry   C2_Entre_Prop
"coqc"  -q  -R . RulerCompassGeometry   C3_Triangles_Egaux
"coqc"  -q  -R . RulerCompassGeometry   C4_Triangles_non_degeneres_egaux
"coqc"  -q  -R . RulerCompassGeometry   C5_Droite_Prop
"coqc"  -q  -R . RulerCompassGeometry   C6_Parallele_Prop
"coqc"  -q  -R . RulerCompassGeometry   C7_DroitesSecantesProp
"coqc"  -q  -R . RulerCompassGeometry   C8_DroitesConfondues
"coqc"  -q  -R . RulerCompassGeometry   C9_Triangles_Emboites
"coqc"  -q  -R . RulerCompassGeometry   C10_Milieu
"coqc"  -q  -R . RulerCompassGeometry   C11_Mediatrice
"coqc"  -q  -R . RulerCompassGeometry   C12_Angles_Opposes
"coqc"  -q  -R . RulerCompassGeometry   C13_Angles_Supplem
"coqc"  -q  -R . RulerCompassGeometry   C14_Angle_Droit
"coqc"  -q  -R . RulerCompassGeometry   C15_Parallelogramm
"coqc"  -q  -R . RulerCompassGeometry   D1_DistanceProp
"coqc"  -q  -R . RulerCompassGeometry   D2_Axe
"coqc"  -q  -R . RulerCompassGeometry   D3_Triangle_Prop
"coqc"  -q  -R . RulerCompassGeometry   D4_CongruenceProp
"coqc"  -q  -R . RulerCompassGeometry   D5_ParalleleConst
"coqc"  -q  -R . RulerCompassGeometry   D6_SumAnglesProp
"coqc"  -q  -R . RulerCompassGeometry   D7_NonParalleles_Secantes
"coqc"  -q  -R . RulerCompassGeometry   E1_Incidence
"coqc"  -q  -R . RulerCompassGeometry   E2_Ordre
"coqc"  -q  -R . RulerCompassGeometry   E3_Congruence
"coqc"  -q  -R . RulerCompassGeometry   E4_Continuite
"coqc"  -q  -R . RulerCompassGeometry   E5_Parallelisme
for i in E5_Parallelisme.vo E4_Continuite.vo E3_Congruence.vo E2_Ordre.vo E1_Incidence.vo D7_NonParalleles_Secantes.vo D6_SumAnglesProp.vo D5_ParalleleConst.vo D4_CongruenceProp.vo D3_Triangle_Prop.vo D2_Axe.vo D1_DistanceProp.vo C9_Triangles_Emboites.vo C8_DroitesConfondues.vo C7_DroitesSecantesProp.vo C6_Parallele_Prop.vo C5_Droite_Prop.vo C4_Triangles_non_degeneres_egaux.vo C3_Triangles_Egaux.vo C2_Entre_Prop.vo C1_DemiDroite_Prop.vo C15_Parallelogramm.vo C14_Angle_Droit.vo C13_Angles_Supplem.vo C12_Angles_Opposes.vo C11_Mediatrice.vo C10_Milieu.vo B9_Inegalite_Triang.vo B8_Point_Def.vo B7_Triangle_Equilateral.vo B6_Cercle_Def.vo B5_Entre_Prel.vo B4_Droite_Def.vo B3_Alignes_Prop.vo B2_Orient_Prop.vo B1_Confondu_Prop.vo B12_Tacticques_base.vo B11_Angle_prop.vo B10_Longueur_Prop.vo A6_Intersection.vo A5_Cercle.vo A4_Droite.vo A3_Metrique.vo A2_Orientation.vo A1_Plan.vo; do \
 install -d `dirname "/home/bench/.opam/system/lib/coq/user-contrib"/RulerCompassGeometry/$i`; \
 install -m 0644 $i "/home/bench/.opam/system/lib/coq/user-contrib"/RulerCompassGeometry/$i; \
done
Installing coq:contrib:ruler-compass-geometry.8.4.dev.

Installation size

Total: 919 K

79 K /home/bench/.opam/system/lib/coq/user-contrib/RulerCompassGeometry/D7_NonParalleles_Secantes.vo

40 K /home/bench/.opam/system/lib/coq/user-contrib/RulerCompassGeometry/D5_ParalleleConst.vo

40 K /home/bench/.opam/system/lib/coq/user-contrib/RulerCompassGeometry/E3_Congruence.vo

37 K /home/bench/.opam/system/lib/coq/user-contrib/RulerCompassGeometry/C4_Triangles_non_degeneres_egaux.vo

37 K /home/bench/.opam/system/lib/coq/user-contrib/RulerCompassGeometry/C10_Milieu.vo

35 K /home/bench/.opam/system/lib/coq/user-contrib/RulerCompassGeometry/D6_SumAnglesProp.vo

34 K /home/bench/.opam/system/lib/coq/user-contrib/RulerCompassGeometry/B12_Tacticques_base.vo

31 K /home/bench/.opam/system/lib/coq/user-contrib/RulerCompassGeometry/C13_Angles_Supplem.vo

30 K /home/bench/.opam/system/lib/coq/user-contrib/RulerCompassGeometry/D2_Axe.vo

29 K /home/bench/.opam/system/lib/coq/user-contrib/RulerCompassGeometry/D4_CongruenceProp.vo

29 K /home/bench/.opam/system/lib/coq/user-contrib/RulerCompassGeometry/E2_Ordre.vo

26 K /home/bench/.opam/system/lib/coq/user-contrib/RulerCompassGeometry/B11_Angle_prop.vo

26 K /home/bench/.opam/system/lib/coq/user-contrib/RulerCompassGeometry/B10_Longueur_Prop.vo

26 K /home/bench/.opam/system/lib/coq/user-contrib/RulerCompassGeometry/C7_DroitesSecantesProp.vo

23 K /home/bench/.opam/system/lib/coq/user-contrib/RulerCompassGeometry/C8_DroitesConfondues.vo

22 K /home/bench/.opam/system/lib/coq/user-contrib/RulerCompassGeometry/D3_Triangle_Prop.vo

22 K /home/bench/.opam/system/lib/coq/user-contrib/RulerCompassGeometry/E5_Parallelisme.vo

21 K /home/bench/.opam/system/lib/coq/user-contrib/RulerCompassGeometry/C11_Mediatrice.vo

21 K /home/bench/.opam/system/lib/coq/user-contrib/RulerCompassGeometry/A6_Intersection.vo

21 K /home/bench/.opam/system/lib/coq/user-contrib/RulerCompassGeometry/C2_Entre_Prop.vo

20 K /home/bench/.opam/system/lib/coq/user-contrib/RulerCompassGeometry/C5_Droite_Prop.vo

20 K /home/bench/.opam/system/lib/coq/user-contrib/RulerCompassGeometry/E1_Incidence.vo

18 K /home/bench/.opam/system/lib/coq/user-contrib/RulerCompassGeometry/E4_Continuite.vo

16 K /home/bench/.opam/system/lib/coq/user-contrib/RulerCompassGeometry/C9_Triangles_Emboites.vo

16 K /home/bench/.opam/system/lib/coq/user-contrib/RulerCompassGeometry/C3_Triangles_Egaux.vo

15 K /home/bench/.opam/system/lib/coq/user-contrib/RulerCompassGeometry/C6_Parallele_Prop.vo

14 K /home/bench/.opam/system/lib/coq/user-contrib/RulerCompassGeometry/B7_Triangle_Equilateral.vo

14 K /home/bench/.opam/system/lib/coq/user-contrib/RulerCompassGeometry/C12_Angles_Opposes.vo

13 K /home/bench/.opam/system/lib/coq/user-contrib/RulerCompassGeometry/D1_DistanceProp.vo

12 K /home/bench/.opam/system/lib/coq/user-contrib/RulerCompassGeometry/B8_Point_Def.vo

12 K /home/bench/.opam/system/lib/coq/user-contrib/RulerCompassGeometry/C14_Angle_Droit.vo

11 K /home/bench/.opam/system/lib/coq/user-contrib/RulerCompassGeometry/A3_Metrique.vo

10 K /home/bench/.opam/system/lib/coq/user-contrib/RulerCompassGeometry/A5_Cercle.vo

10 K /home/bench/.opam/system/lib/coq/user-contrib/RulerCompassGeometry/C15_Parallelogramm.vo

9 K /home/bench/.opam/system/lib/coq/user-contrib/RulerCompassGeometry/B2_Orient_Prop.vo

9 K /home/bench/.opam/system/lib/coq/user-contrib/RulerCompassGeometry/A2_Orientation.vo

8 K /home/bench/.opam/system/lib/coq/user-contrib/RulerCompassGeometry/A4_Droite.vo

8 K /home/bench/.opam/system/lib/coq/user-contrib/RulerCompassGeometry/B3_Alignes_Prop.vo

6 K /home/bench/.opam/system/lib/coq/user-contrib/RulerCompassGeometry/B5_Entre_Prel.vo

6 K /home/bench/.opam/system/lib/coq/user-contrib/RulerCompassGeometry/C1_DemiDroite_Prop.vo

4 K /home/bench/.opam/system/lib/coq/user-contrib/RulerCompassGeometry/A1_Plan.vo

4 K /home/bench/.opam/system/lib/coq/user-contrib/RulerCompassGeometry/B6_Cercle_Def.vo

4 K /home/bench/.opam/system/lib/coq/user-contrib/RulerCompassGeometry/B1_Confondu_Prop.vo

4 K /home/bench/.opam/system/lib/coq/user-contrib/RulerCompassGeometry/B4_Droite_Def.vo

3 K /home/bench/.opam/system/lib/coq/user-contrib/RulerCompassGeometry/B9_Inegalite_Triang.vo

1 K /home/bench/.opam/system/lib/coq:contrib:ruler-compass-geometry/opam.config

1 K /home/bench/.opam/system/install/coq:contrib:ruler-compass-geometry.install

Uninstall

Command

opam remove -y coq:contrib:ruler-compass-geometry.8.4.dev

Return code

0

Duration

2 s

Output

The following actions will be performed:
 - remove    coq:contrib:ruler-compass-geometry.8.4.dev
=== 1 to remove ===
=-=- Synchronizing package archives -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
[coq:contrib:ruler-compass-geometry] Fetching https://gforge.inria.fr/git/coq-contribs/ruler-compass-geometry.git#v8.4
=-=- Removing Packages =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
Removing coq:contrib:ruler-compass-geometry.8.4.dev.
  rm -R /home/bench/.opam/system/lib/coq/user-contrib/RulerCompassGeometry

Missing removes

                none

Wrong removes

                none

          Sources are on GitHub. © Guillaume Claret.


text:
'use strict';

const
 bodyParser = require('body-parser'),
 express = require('express'),
 xhub = require('express-x-hub'),
 crypto = require('crypto');

const APP_SECRET = (process.env.APP_SECRET) ?
  process.env.APP_SECRET :
  config.get('APP_SECRET');

const VERIFY_TOKEN = (process.env.VERIFY_TOKEN) ?
  (process.env.VERIFY_TOKEN) :
  config.get('VERIFY_TOKEN');

const ACCESS_TOKEN = (process.env.ACCESS_TOKEN) ?
  (process.env.ACCESS_TOKEN) :
  config.get('ACCESS_TOKEN');

var received_updates = [];

var app = express();
var port = process.env.PORT || 1338;
app.use(xhub({ algorithm: 'sha1', secret: APP_SECRET }));
app.use(bodyParser.json());
//app.use(bodyParser.json({ verify: verifyRequestSignature }));

function verifyRequestSignature(req, res, buf) {
  var signature = req.headers['x-hub-signature'];

  if (!signature) {
    // For testing, let's log an error. In production, you should throw an
    // error.
    console.error('Couldn\'t validate the signature.');
  } else {
    var elements = signature.split('=');
    var signatureHash = elements[1];

    var expectedHash = crypto.createHmac('sha1', APP_SECRET).update(buf).digest('hex');

    if (signatureHash != expectedHash) {
      throw new Error('Couldn\'t validate the request signature.');
    }
  }
}

process.on('uncaughtException', function(err)
{
    console.log(err);
});

app.listen(port, function () {

    console.log( "Express server listening on port " + port);
});

app.get('/', function(req, res) {

console.log('hub verify token: ' + req.param['hub.verify_token']);
 if(req.query['hub.verify_token'] === VERIFY_TOKEN)
 {
    console.log('Validating webhook');
    res.status(200).send(req.query['hub.challenge']);
 }
 else
 {
    console.error('Failed validation. Make sure the validation tokens match.');
    res.sendStatus(403);
  }
  //console.log(req);
  //console.log('Recieving1...' + req.param('hub.verify_token'));
  //res.send(req.param('hub.challenge'));

});

app.post('/', function(req, res)
{

  console.log('Inside app post function to extract receieved WP post');
  /*
  if (!req.isXHubValid())
  {
    console.log('Warning - request header X-Hub-Signature not present or invalid');
    res.sendStatus(401);
    return;
  }

   // console.log("RES: " + res);
   // console.log("REQ BODY: " + req.body);
   // console.log('request header X-Hub-Signature validated');

    // Process the Facebook updates here
    received_updates.unshift(req.body);
    res.sendStatus(200);
  */
   if (req.isXHubValid())
   {
    try{
        var data = req.body;
        console.log('DATA OBJECT: ' + data.object);
        // On Workplace, webhooks can be sent for page, group, user and
    		// workplace_security objects
        switch (data.object) {
        case 'page':
          processPageEvents(data);
          break;
        case 'group':
          processGroupEvents(data);
          break;
        case 'user':
          processUserEvents(data);
          break;
        case 'workplace_security':
          processWorkplaceSecurityEvents(data);
          break;
        default:
          console.log('Unhandled Webhook Object', data.object);
        }
      } catch (e) {
        // Write out any exceptions for now
        console.error(e);
      } finally {
        // Always respond with a 200 OK for handled webhooks, to avoid retries
    		// from Facebook
        res.sendStatus(200);
      }
   }
   else
   {
    console.log('Warning - request header X-Hub-Signature not present or invalid');
    res.sendStatus(401);
    return;
   }
});

function processPageEvents(data)
{
  data.entry.forEach(function(entry){
    let page_id = entry.id;
		// Chat messages sent to the page
    if(entry.messaging) {
      entry.messaging.forEach(function(messaging_event){
        console.log('Page Messaging Event',page_id,messaging_event);
      });
    }
		// Page related changes, or mentions of the page
    if(entry.changes) {
      entry.changes.forEach(function(change){
        console.log('Page Change',page_id,change);
      });
    }
  });
}

function processGroupEvents(data)
{
  data.entry.forEach(function(entry)
  {
    if(entry.changes[0].field === 'comments')
    {
      console.log('This is comment');
      console.log("Group ID: " + entry.id);
      console.log("From : " + entry.changes[0].value["from"]);
      console.log("Post ID: " + entry.changes[0].value["post_id"] );
      console.log("Created at: " + entry.changes[0].value["created_time"]);
      console.log("Message: " + entry.changes[0].value["message"]);

    }
    else   if(entry.changes[0].field === 'posts')
    {
       console.log('This is post');
       console.log("From : " + entry.changes[0].value["from"]);
       console.log("Post ID: " + entry.changes[0].value["post_id"] );
       console.log("Created at: " + entry.changes[0].value["created_time"]);
       console.log("Message: " + entry.changes[0].value["message"]);
    }

    if(entry.changes[0].value["attachments"] !=null &&
      entry.changes[0].value["attachments"].data.length > 0)
    {
      console.log('Attachments length: ' + entry.changes[0].value["attachments"].data.length);
      console.log(entry.changes[0].value["attachments"].data);
      var length = entry.changes[0].value["attachments"].data.length;
      for(var x=0; x<length; x++)
      {
        console.log("Attachment URL:"  + entry.changes[0].value["attachments"].data['url']);
      }
    }

      entry.changes.forEach(function(change){
        console.log(change);

      });
  });
}

function processUserEvents(data)
{
  data.entry.forEach(function(entry){
    let group_id = entry.id;
    entry.changes.forEach(function(change){
      console.log('User Change',group_id,change);
    });
  });
}

function processWorkplaceSecurityEvents(data)
{
  data.entry.forEach(function(entry){
    let group_id = entry.id;
    entry.changes.forEach(function(change){
      console.log('Workplace Security Change',group_id,change);
    });
  });
}

redpajama_set_name: RedPajamaGithub


text:
package org.apache.druid.segment.virtual;

import com.google.common.collect.ImmutableMap;
import org.apache.druid.common.config.NullHandling;
import org.apache.druid.math.expr.ExpressionType;
import org.apache.druid.math.expr.Parser;
import org.apache.druid.query.expression.TestExprMacroTable;
import org.apache.druid.segment.ColumnInspector;
import org.apache.druid.segment.column.ColumnCapabilities;
import org.apache.druid.segment.column.ColumnCapabilitiesImpl;
import org.apache.druid.segment.column.ColumnType;
import org.apache.druid.segment.column.ValueType;
import org.apache.druid.testing.InitializedNullHandlingTest;
import org.junit.Assert;
import org.junit.Rule;
import org.junit.Test;
import org.junit.rules.ExpectedException;

import javax.annotation.Nullable;
import java.util.Map;

public class ExpressionPlannerTest extends InitializedNullHandlingTest
{
  public static final ColumnInspector SYNTHETIC_INSPECTOR = new ColumnInspector()
  {
    private final Map<String, ColumnCapabilities> capabilitiesMap =
        ImmutableMap.<String, ColumnCapabilities>builder()
                    .put(
                        "long1",
                        ColumnCapabilitiesImpl.createSimpleNumericColumnCapabilities(ColumnType.LONG)
                    )
                    .put(
                        "long2",
                        ColumnCapabilitiesImpl.createSimpleNumericColumnCapabilities(ColumnType.LONG)
                    )
                    .put(
                        "float1",
                        ColumnCapabilitiesImpl.createSimpleNumericColumnCapabilities(ColumnType.FLOAT)
                    )
                    .put(
                        "float2",
                        ColumnCapabilitiesImpl.createSimpleNumericColumnCapabilities(ColumnType.FLOAT)
                    )
                    .put(
                        "double1",
                        ColumnCapabilitiesImpl.createSimpleNumericColumnCapabilities(ColumnType.DOUBLE)
                    )
                    .put(
                        "double2",
                        ColumnCapabilitiesImpl.createSimpleNumericColumnCapabilities(ColumnType.DOUBLE)
                    )
                    .put(
                        "scalar_string",
                        ColumnCapabilitiesImpl.createSimpleSingleValueStringColumnCapabilities()
                    )
                    .put(
                        // segment style single value dictionary encoded with unique sorted dictionary
                        "scalar_dictionary_string",
                        new ColumnCapabilitiesImpl().setType(ColumnType.STRING)
                                                    .setDictionaryEncoded(true)
                                                    .setHasBitmapIndexes(true)
                                                    .setDictionaryValuesSorted(true)
                                                    .setDictionaryValuesUnique(true)
                                                    .setHasMultipleValues(false)
                    )
                    .put(
                        // dictionary encoded but not unique or sorted, maybe an indexed table from a join result
                        "scalar_dictionary_string_nonunique",
                        new ColumnCapabilitiesImpl().setType(ColumnType.STRING)
                                                    .setDictionaryEncoded(true)
                                                    .setHasBitmapIndexes(false)
                                                    .setDictionaryValuesSorted(false)
                                                    .setDictionaryValuesUnique(false)
                                                    .setHasMultipleValues(false)
                    )
                    .put(
                        // string with unknown multi-valuedness
                        "string_unknown",
                        new ColumnCapabilitiesImpl().setType(ColumnType.STRING)
                    )
                    .put(
                        // dictionary encoded multi valued string dimension
                        "multi_dictionary_string",
                        new ColumnCapabilitiesImpl().setType(ColumnType.STRING)
                                                    .setDictionaryEncoded(true)
                                                    .setHasBitmapIndexes(true)
                                                    .setDictionaryValuesUnique(true)
                                                    .setDictionaryValuesSorted(true)
                                                    .setHasMultipleValues(true)
                    )
                    .put(
                        // simple multi valued string dimension unsorted
                        "multi_dictionary_string_nonunique",
                        new ColumnCapabilitiesImpl().setType(ColumnType.STRING)
                                                    .setDictionaryEncoded(false)
                                                    .setHasBitmapIndexes(false)
                                                    .setDictionaryValuesUnique(false)
                                                    .setDictionaryValuesSorted(false)
                                                    .setHasMultipleValues(true)
                    )
                    .put(
                        "string_array_1",
                        ColumnCapabilitiesImpl.createSimpleArrayColumnCapabilities(ColumnType.STRING_ARRAY)
                    )
                    .put(
                        "string_array_2",
                        ColumnCapabilitiesImpl.createSimpleArrayColumnCapabilities(ColumnType.STRING_ARRAY)
                    )
                    .put(
                        "long_array_1",
                        ColumnCapabilitiesImpl.createSimpleArrayColumnCapabilities(ColumnType.LONG_ARRAY)
                    )
                    .put(
                        "long_array_2",
                        ColumnCapabilitiesImpl.createSimpleArrayColumnCapabilities(ColumnType.LONG_ARRAY)
                    )
                    .put(
                        "double_array_1",
                        ColumnCapabilitiesImpl.createSimpleArrayColumnCapabilities(ColumnType.DOUBLE_ARRAY)
                    )
                    .put(
                        "double_array_2",
                        ColumnCapabilitiesImpl.createSimpleArrayColumnCapabilities(ColumnType.DOUBLE_ARRAY)
                    )
                    .build();

    @Nullable
    @Override
    public ColumnCapabilities getColumnCapabilities(String column)
    {
      return capabilitiesMap.get(column);
    }
  };

  @Rule
  public ExpectedException expectedException = ExpectedException.none();

  @Test
  public void testUnknown()
  {
    // column has no capabilities
    // the vectorize query engine contracts is such that the lack of column capabilities is indicative of a nil column
    // so this is vectorizable
    // for non-vectorized expression processing, this will probably end up using a selector that examines inputs on a
    // row by row basis to determine if the expression needs applied to multi-valued inputs

    ExpressionPlan thePlan = plan("concat(x, 'x')");
    Assert.assertTrue(
        thePlan.is(
            ExpressionPlan.Trait.UNKNOWN_INPUTS,
            ExpressionPlan.Trait.VECTORIZABLE
        )
    );
    Assert.assertFalse(
        thePlan.is(
            ExpressionPlan.Trait.NEEDS_APPLIED,
            ExpressionPlan.Trait.INCOMPLETE_INPUTS,
            ExpressionPlan.Trait.SINGLE_INPUT_SCALAR,
            ExpressionPlan.Trait.SINGLE_INPUT_MAPPABLE,
            ExpressionPlan.Trait.NON_SCALAR_OUTPUT,
            ExpressionPlan.Trait.CONSTANT
        )
    );
    // this expression has no "unapplied bindings", nothing to apply
    Assert.assertEquals("concat(\"x\", 'x')", thePlan.getAppliedExpression().stringify());
    Assert.assertEquals("concat(\"x\", 'x')", thePlan.getAppliedFoldExpression("__acc").stringify());
    Assert.assertEquals(ExpressionType.STRING, thePlan.getOutputType());
    ColumnCapabilities inferred = thePlan.inferColumnCapabilities(null);
    Assert.assertNotNull(inferred);
    Assert.assertEquals(ValueType.STRING, inferred.getType());
    Assert.assertTrue(inferred.hasNulls().isTrue());
    Assert.assertFalse(inferred.isDictionaryEncoded().isMaybeTrue());
    Assert.assertFalse(inferred.areDictionaryValuesSorted().isMaybeTrue());
    Assert.assertFalse(inferred.areDictionaryValuesUnique().isMaybeTrue());
    Assert.assertFalse(inferred.hasMultipleValues().isMaybeTrue());
    Assert.assertFalse(inferred.hasBitmapIndexes());
    Assert.assertFalse(inferred.hasSpatialIndexes());

    // what if both inputs are unknown, can we know things?
    thePlan = plan("x * y");
    Assert.assertTrue(
        thePlan.is(
            ExpressionPlan.Trait.UNKNOWN_INPUTS
        )
    );
    Assert.assertFalse(
        thePlan.is(
            ExpressionPlan.Trait.NEEDS_APPLIED,
            ExpressionPlan.Trait.VECTORIZABLE,
            ExpressionPlan.Trait.INCOMPLETE_INPUTS,
            ExpressionPlan.Trait.SINGLE_INPUT_SCALAR,
            ExpressionPlan.Trait.SINGLE_INPUT_MAPPABLE,
            ExpressionPlan.Trait.NON_SCALAR_OUTPUT,
            ExpressionPlan.Trait.CONSTANT
        )
    );

    Assert.assertEquals("(\"x\" * \"y\")", thePlan.getAppliedExpression().stringify());
    Assert.assertEquals("(\"x\" * \"y\")", thePlan.getAppliedFoldExpression("__acc").stringify());
    Assert.assertNull(thePlan.getOutputType());
    Assert.assertNull(thePlan.inferColumnCapabilities(null));
    // no we cannot
  }

  @Test
  public void testScalarStringNondictionaryEncoded()
  {
    ExpressionPlan thePlan = plan("concat(scalar_string, 'x')");
    Assert.assertTrue(
        thePlan.is(
            ExpressionPlan.Trait.VECTORIZABLE
        )
    );
    Assert.assertFalse(
        thePlan.is(
            ExpressionPlan.Trait.SINGLE_INPUT_SCALAR,
            ExpressionPlan.Trait.SINGLE_INPUT_MAPPABLE,
            ExpressionPlan.Trait.INCOMPLETE_INPUTS,
            ExpressionPlan.Trait.UNKNOWN_INPUTS,
            ExpressionPlan.Trait.NEEDS_APPLIED,
            ExpressionPlan.Trait.NON_SCALAR_INPUTS,
            ExpressionPlan.Trait.NON_SCALAR_OUTPUT
        )
    );
    Assert.assertEquals("concat(\"scalar_string\", 'x')", thePlan.getAppliedExpression().stringify());
    Assert.assertEquals("concat(\"scalar_string\", 'x')", thePlan.getAppliedFoldExpression("__acc").stringify());
    Assert.assertEquals(ExpressionType.STRING, thePlan.getOutputType());
    ColumnCapabilities inferred = thePlan.inferColumnCapabilities(null);
    Assert.assertNotNull(inferred);
    Assert.assertEquals(ValueType.STRING, inferred.getType());
    Assert.assertTrue(inferred.hasNulls().isTrue());
    Assert.assertFalse(inferred.isDictionaryEncoded().isMaybeTrue());
    Assert.assertFalse(inferred.areDictionaryValuesSorted().isMaybeTrue());
    Assert.assertFalse(inferred.areDictionaryValuesUnique().isMaybeTrue());
    Assert.assertFalse(inferred.hasMultipleValues().isMaybeTrue());
    Assert.assertFalse(inferred.hasBitmapIndexes());
    Assert.assertFalse(inferred.hasSpatialIndexes());
  }

  @Test
  public void testScalarNumeric()
  {
    ExpressionPlan thePlan = plan("long1 + 5");
    Assert.assertTrue(
        thePlan.is(
            ExpressionPlan.Trait.SINGLE_INPUT_SCALAR,
            ExpressionPlan.Trait.VECTORIZABLE
        )
    );
    Assert.assertFalse(
        thePlan.is(
            ExpressionPlan.Trait.SINGLE_INPUT_MAPPABLE,
            ExpressionPlan.Trait.INCOMPLETE_INPUTS,
            ExpressionPlan.Trait.UNKNOWN_INPUTS,
            ExpressionPlan.Trait.NEEDS_APPLIED,
            ExpressionPlan.Trait.NON_SCALAR_INPUTS,
            ExpressionPlan.Trait.NON_SCALAR_OUTPUT
        )
    );
    Assert.assertEquals("(\"long1\" + 5)", thePlan.getAppliedExpression().stringify());
    Assert.assertEquals("(\"long1\" + 5)", thePlan.getAppliedFoldExpression("__acc").stringify());
    Assert.assertEquals("(\"long1\" + 5)", thePlan.getAppliedFoldExpression("long1").stringify());
    Assert.assertEquals(ExpressionType.LONG, thePlan.getOutputType());
    ColumnCapabilities inferred = thePlan.inferColumnCapabilities(null);
    Assert.assertNotNull(inferred);
    Assert.assertEquals(ValueType.LONG, inferred.getType());
    if (NullHandling.sqlCompatible()) {
      Assert.assertTrue(inferred.hasNulls().isMaybeTrue());
    } else {
      Assert.assertFalse(inferred.hasNulls().isMaybeTrue());
    }
    Assert.assertFalse(inferred.isDictionaryEncoded().isMaybeTrue());
    Assert.assertFalse(inferred.areDictionaryValuesSorted().isMaybeTrue());
    Assert.assertFalse(inferred.areDictionaryValuesUnique().isMaybeTrue());
    Assert.assertFalse(inferred.hasMultipleValues().isMaybeTrue());
    Assert.assertFalse(inferred.hasBitmapIndexes());
    Assert.assertFalse(inferred.hasSpatialIndexes());

    thePlan = plan("long1 + 5.0");
    Assert.assertEquals(ExpressionType.DOUBLE, thePlan.getOutputType());

    thePlan = plan("double1 * double2");
    Assert.assertTrue(
        thePlan.is(
            ExpressionPlan.Trait.VECTORIZABLE
        )
    );
    Assert.assertFalse(
        thePlan.is(
            ExpressionPlan.Trait.SINGLE_INPUT_SCALAR,
            ExpressionPlan.Trait.SINGLE_INPUT_MAPPABLE,
            ExpressionPlan.Trait.INCOMPLETE_INPUTS,
            ExpressionPlan.Trait.UNKNOWN_INPUTS,
            ExpressionPlan.Trait.NEEDS_APPLIED,
            ExpressionPlan.Trait.NON_SCALAR_INPUTS,
            ExpressionPlan.Trait.NON_SCALAR_OUTPUT
        )
    );
    Assert.assertEquals("(\"double1\" * \"double2\")", thePlan.getAppliedExpression().stringify());
    Assert.assertEquals("(\"double1\" * \"double2\")", thePlan.getAppliedFoldExpression("__acc").stringify());
    Assert.assertEquals("(\"double1\" * \"double2\")", thePlan.getAppliedFoldExpression("double1").stringify());
    Assert.assertEquals(ExpressionType.DOUBLE, thePlan.getOutputType());
    inferred = thePlan.inferColumnCapabilities(null);
    Assert.assertNotNull(inferred);
    Assert.assertEquals(ValueType.DOUBLE, inferred.getType());
    if (NullHandling.sqlCompatible()) {
      Assert.assertTrue(inferred.hasNulls().isMaybeTrue());
    } else {
      Assert.assertFalse(inferred.hasNulls().isMaybeTrue());
    }
    Assert.assertFalse(inferred.isDictionaryEncoded().isMaybeTrue());
    Assert.assertFalse(inferred.areDictionaryValuesSorted().isMaybeTrue());
    Assert.assertFalse(inferred.areDictionaryValuesUnique().isMaybeTrue());
    Assert.assertFalse(inferred.hasMultipleValues().isMaybeTrue());
    Assert.assertFalse(inferred.hasBitmapIndexes());
    Assert.assertFalse(inferred.hasSpatialIndexes());
  }

  @Test
  public void testScalarStringDictionaryEncoded()
  {
    ExpressionPlan thePlan = plan("concat(scalar_dictionary_string, 'x')");
    Assert.assertTrue(
        thePlan.is(
            ExpressionPlan.Trait.SINGLE_INPUT_SCALAR,
            ExpressionPlan.Trait.SINGLE_INPUT_MAPPABLE,
            ExpressionPlan.Trait.VECTORIZABLE
        )
    );
    Assert.assertFalse(
        thePlan.is(
            ExpressionPlan.Trait.INCOMPLETE_INPUTS,
            ExpressionPlan.Trait.UNKNOWN_INPUTS,
            ExpressionPlan.Trait.NEEDS_APPLIED,
            ExpressionPlan.Trait.NON_SCALAR_INPUTS,
            ExpressionPlan.Trait.NON_SCALAR_OUTPUT
        )
    );
    Assert.assertEquals("concat(\"scalar_dictionary_string\", 'x')", thePlan.getAppliedExpression().stringify());
    Assert.assertEquals(
        "concat(\"scalar_dictionary_string\", 'x')",
        thePlan.getAppliedFoldExpression("__acc").stringify()
    );
    Assert.assertEquals(ExpressionType.STRING, thePlan.getOutputType());
    ColumnCapabilities inferred = thePlan.inferColumnCapabilities(null);
    Assert.assertNotNull(inferred);
    Assert.assertEquals(ValueType.STRING, inferred.getType());
    Assert.assertTrue(inferred.hasNulls().isTrue());
    Assert.assertTrue(inferred.isDictionaryEncoded().isTrue());
    Assert.assertFalse(inferred.areDictionaryValuesSorted().isMaybeTrue());
    Assert.assertFalse(inferred.areDictionaryValuesUnique().isMaybeTrue());
    Assert.assertFalse(inferred.hasMultipleValues().isMaybeTrue());
    Assert.assertTrue(inferred.hasBitmapIndexes());
    Assert.assertFalse(inferred.hasSpatialIndexes());

    // multiple input columns
    thePlan = plan("concat(scalar_dictionary_string, scalar_dictionary_string_nonunique)");
    Assert.assertTrue(
        thePlan.is(
            ExpressionPlan.Trait.VECTORIZABLE
        )
    );
    Assert.assertFalse(
        thePlan.is(
            ExpressionPlan.Trait.SINGLE_INPUT_SCALAR,
            ExpressionPlan.Trait.SINGLE_INPUT_MAPPABLE,
            ExpressionPlan.Trait.INCOMPLETE_INPUTS,
            ExpressionPlan.Trait.UNKNOWN_INPUTS,
            ExpressionPlan.Trait.NEEDS_APPLIED,
            ExpressionPlan.Trait.NON_SCALAR_INPUTS,
            ExpressionPlan.Trait.NON_SCALAR_OUTPUT
        )
    );
    Assert.assertEquals(
        "concat(\"scalar_dictionary_string\", \"scalar_dictionary_string_nonunique\")",
        thePlan.getAppliedExpression().stringify()
    );
    Assert.assertEquals(
        "concat(\"scalar_dictionary_string\", \"scalar_dictionary_string_nonunique\")",
        thePlan.getAppliedFoldExpression("__acc").stringify()
    );
    // what if scalar_dictionary_string_nonunique is an accumulator instead? nope, still no NEEDS_APPLIED so nothing to do
    Assert.assertEquals(
        "concat(\"scalar_dictionary_string\", \"scalar_dictionary_string_nonunique\")",
        thePlan.getAppliedFoldExpression("scalar_dictionary_string_nonunique").stringify()
    );
    Assert.assertEquals(ExpressionType.STRING, thePlan.getOutputType());
    inferred = thePlan.inferColumnCapabilities(null);
    Assert.assertNotNull(inferred);
    Assert.assertEquals(ValueType.STRING, inferred.getType());
    Assert.assertTrue(inferred.hasNulls().isTrue());
    Assert.assertFalse(inferred.isDictionaryEncoded().isMaybeTrue());
    Assert.assertFalse(inferred.areDictionaryValuesSorted().isMaybeTrue());
    Assert.assertFalse(inferred.areDictionaryValuesUnique().isMaybeTrue());
    Assert.assertFalse(inferred.hasMultipleValues().isMaybeTrue());
    Assert.assertFalse(inferred.hasBitmapIndexes());
    Assert.assertFalse(inferred.hasSpatialIndexes());

    // array output of dictionary encoded string are not considered single scalar/mappable, nor vectorizable
    thePlan = plan("array(scalar_dictionary_string)");
    Assert.assertTrue(
        thePlan.is(
            ExpressionPlan.Trait.NON_SCALAR_OUTPUT
        )
    );
    Assert.assertFalse(
        thePlan.is(
            ExpressionPlan.Trait.INCOMPLETE_INPUTS,
            ExpressionPlan.Trait.UNKNOWN_INPUTS,
            ExpressionPlan.Trait.NEEDS_APPLIED,
            ExpressionPlan.Trait.NON_SCALAR_INPUTS,
            ExpressionPlan.Trait.SINGLE_INPUT_SCALAR,
            ExpressionPlan.Trait.SINGLE_INPUT_MAPPABLE,
            ExpressionPlan.Trait.VECTORIZABLE
        )
    );
  }

  @Test
  public void testMultiValueStringDictionaryEncoded()
  {
    ExpressionPlan thePlan = plan("concat(multi_dictionary_string, 'x')");
    Assert.assertTrue(
        thePlan.is(
            ExpressionPlan.Trait.NEEDS_APPLIED,
            ExpressionPlan.Trait.SINGLE_INPUT_MAPPABLE
        )
    );
    Assert.assertFalse(
        thePlan.is(
            ExpressionPlan.Trait.INCOMPLETE_INPUTS,
            ExpressionPlan.Trait.UNKNOWN_INPUTS,
            ExpressionPlan.Trait.NON_SCALAR_INPUTS,
            ExpressionPlan.Trait.NON_SCALAR_OUTPUT,
            ExpressionPlan.Trait.VECTORIZABLE
        )
    );
    Assert.assertEquals(ExpressionType.STRING, thePlan.getOutputType());
    ColumnCapabilities inferred = thePlan.inferColumnCapabilities(null);
    Assert.assertNotNull(inferred);
    Assert.assertEquals(ValueType.STRING, inferred.getType());
    Assert.assertTrue(inferred.hasNulls().isMaybeTrue());
    Assert.assertTrue(inferred.isDictionaryEncoded().isTrue());
    Assert.assertFalse(inferred.areDictionaryValuesSorted().isMaybeTrue());
    Assert.assertFalse(inferred.areDictionaryValuesUnique().isMaybeTrue());
    Assert.assertTrue(inferred.hasMultipleValues().isTrue());
    Assert.assertTrue(inferred.hasBitmapIndexes());
    Assert.assertFalse(inferred.hasSpatialIndexes());

    thePlan = plan("concat(scalar_string, multi_dictionary_string_nonunique)");
    Assert.assertTrue(
        thePlan.is(
            ExpressionPlan.Trait.NEEDS_APPLIED
        )
    );
    Assert.assertFalse(
        thePlan.is(
            ExpressionPlan.Trait.INCOMPLETE_INPUTS,
            ExpressionPlan.Trait.UNKNOWN_INPUTS,
            ExpressionPlan.Trait.NON_SCALAR_INPUTS,
            ExpressionPlan.Trait.NON_SCALAR_OUTPUT,
            ExpressionPlan.Trait.VECTORIZABLE
        )
    );
    Assert.assertEquals(
        "map((\"multi_dictionary_string_nonunique\") -> concat(\"scalar_string\", \"multi_dictionary_string_nonunique\"), \"multi_dictionary_string_nonunique\")",
        thePlan.getAppliedExpression().stringify()
    );
    Assert.assertEquals(
        "fold((\"multi_dictionary_string_nonunique\", \"scalar_string\") -> concat(\"scalar_string\", \"multi_dictionary_string_nonunique\"), \"multi_dictionary_string_nonunique\", \"scalar_string\")",
        thePlan.getAppliedFoldExpression("scalar_string").stringify()
    );
    Assert.assertEquals(ExpressionType.STRING, thePlan.getOutputType());
    inferred = thePlan.inferColumnCapabilities(null);
    Assert.assertNotNull(inferred);
    Assert.assertEquals(ValueType.STRING, inferred.getType());
    Assert.assertTrue(inferred.hasMultipleValues().isTrue());

    thePlan = plan("concat(multi_dictionary_string, multi_dictionary_string_nonunique)");
    Assert.assertTrue(
        thePlan.is(
            ExpressionPlan.Trait.NEEDS_APPLIED
        )
    );
    Assert.assertFalse(
        thePlan.is(
            ExpressionPlan.Trait.INCOMPLETE_INPUTS,
            ExpressionPlan.Trait.UNKNOWN_INPUTS,
            ExpressionPlan.Trait.NON_SCALAR_INPUTS,
            ExpressionPlan.Trait.NON_SCALAR_OUTPUT,
            ExpressionPlan.Trait.VECTORIZABLE
        )
    );
    Assert.assertEquals(ExpressionType.STRING, thePlan.getOutputType());
    // whoa
    Assert.assertEquals(
        "cartesian_map((\"multi_dictionary_string\", \"multi_dictionary_string_nonunique\") -> concat(\"multi_dictionary_string\", \"multi_dictionary_string_nonunique\"), \"multi_dictionary_string\", \"multi_dictionary_string_nonunique\")",
        thePlan.getAppliedExpression().stringify()
    );
    // sort of funny, but technically correct
    Assert.assertEquals(
        "cartesian_fold((\"multi_dictionary_string\", \"multi_dictionary_string_nonunique\", \"__acc\") -> concat(\"multi_dictionary_string\", \"multi_dictionary_string_nonunique\"), \"multi_dictionary_string\", \"multi_dictionary_string_nonunique\", \"__acc\")",
        thePlan.getAppliedFoldExpression("__acc").stringify()
    );
    inferred = thePlan.inferColumnCapabilities(null);
    Assert.assertNotNull(inferred);
    Assert.assertEquals(ValueType.STRING, inferred.getType());
    Assert.assertTrue(inferred.hasMultipleValues().isTrue());

    thePlan = plan("array_append(multi_dictionary_string, 'foo')");
    Assert.assertTrue(
        thePlan.is(
            ExpressionPlan.Trait.NON_SCALAR_OUTPUT
        )
    );
    Assert.assertFalse(
        thePlan.is(
            ExpressionPlan.Trait.NEEDS_APPLIED,
            ExpressionPlan.Trait.INCOMPLETE_INPUTS,
            ExpressionPlan.Trait.UNKNOWN_INPUTS,
            ExpressionPlan.Trait.NON_SCALAR_INPUTS,
            ExpressionPlan.Trait.VECTORIZABLE
        )
    );
  }

  @Test
  public void testMultiValueStringDictionaryEncodedIllegalAccumulator()
  {
    expectedException.expect(IllegalStateException.class);
    expectedException.expectMessage(
        "Accumulator cannot be implicitly transformed, if it is an ARRAY or multi-valued type it must be used explicitly as such"
    );
    ExpressionPlan thePlan = plan("concat(multi_dictionary_string, 'x')");
    Assert.assertTrue(
        thePlan.is(
            ExpressionPlan.Trait.NEEDS_APPLIED,
            ExpressionPlan.Trait.SINGLE_INPUT_MAPPABLE
        )
    );
    Assert.assertFalse(
        thePlan.is(
            ExpressionPlan.Trait.INCOMPLETE_INPUTS,
            ExpressionPlan.Trait.UNKNOWN_INPUTS,
            ExpressionPlan.Trait.NON_SCALAR_INPUTS,
            ExpressionPlan.Trait.NON_SCALAR_OUTPUT,
            ExpressionPlan.Trait.VECTORIZABLE
        )
    );
    Assert.assertEquals(ExpressionType.STRING, thePlan.getOutputType());

    thePlan = plan("concat(multi_dictionary_string, multi_dictionary_string_nonunique)");
    Assert.assertTrue(
        thePlan.is(
            ExpressionPlan.Trait.NEEDS_APPLIED
        )
    );
    Assert.assertFalse(
        thePlan.is(
            ExpressionPlan.Trait.INCOMPLETE_INPUTS,
            ExpressionPlan.Trait.UNKNOWN_INPUTS,
            ExpressionPlan.Trait.NON_SCALAR_INPUTS,
            ExpressionPlan.Trait.NON_SCALAR_OUTPUT,
            ExpressionPlan.Trait.VECTORIZABLE
        )
    );
    // what happens if we try to use a multi-valued input that was not explicitly used as multi-valued as the
    // accumulator?
    thePlan.getAppliedFoldExpression("multi_dictionary_string");
    Assert.assertEquals(ExpressionType.STRING, thePlan.getOutputType());
  }

  @Test
  public void testIncompleteString()
  {
    ExpressionPlan thePlan = plan("concat(string_unknown, 'x')");
    Assert.assertTrue(
        thePlan.is(
            ExpressionPlan.Trait.INCOMPLETE_INPUTS
        )
    );
    Assert.assertFalse(
        thePlan.is(
            ExpressionPlan.Trait.SINGLE_INPUT_SCALAR,
            ExpressionPlan.Trait.SINGLE_INPUT_MAPPABLE,
            ExpressionPlan.Trait.UNKNOWN_INPUTS,
            ExpressionPlan.Trait.NEEDS_APPLIED,
            ExpressionPlan.Trait.NON_SCALAR_INPUTS,
            ExpressionPlan.Trait.NON_SCALAR_OUTPUT,
            ExpressionPlan.Trait.VECTORIZABLE
        )
    );
    // incomplete inputs are not transformed either, rather this will need to be detected and handled on a row-by-row
    // basis
    Assert.assertEquals("concat(\"string_unknown\", 'x')", thePlan.getAppliedExpression().stringify());
    Assert.assertEquals("concat(\"string_unknown\", 'x')", thePlan.getAppliedFoldExpression("__acc").stringify());
    // incomplete and unknown skip output type since we don't reliably know
    Assert.assertNull(thePlan.getOutputType());
    Assert.assertNull(thePlan.inferColumnCapabilities(null));
  }

  @Test
  public void testArrayOutput()
  {
    // its ok to use scalar inputs to array expressions, string columns cant help it if sometimes they are single
    // valued and sometimes they are multi-valued
    ExpressionPlan thePlan = plan("array_append(scalar_string, 'x')");
    assertArrayInAndOut(thePlan);
    // with a string hint, it should look like a multi-valued string
    ColumnCapabilities inferred = thePlan.inferColumnCapabilities(ColumnType.STRING);
    Assert.assertNotNull(inferred);
    Assert.assertEquals(ValueType.STRING, inferred.getType());
    Assert.assertTrue(inferred.hasNulls().isMaybeTrue());
    Assert.assertFalse(inferred.isDictionaryEncoded().isMaybeTrue());
    Assert.assertFalse(inferred.areDictionaryValuesSorted().isMaybeTrue());
    Assert.assertFalse(inferred.areDictionaryValuesUnique().isMaybeTrue());
    Assert.assertTrue(inferred.hasMultipleValues().isTrue());
    Assert.assertFalse(inferred.hasBitmapIndexes());
    Assert.assertFalse(inferred.hasSpatialIndexes());
    // with no hint though, let the array free
    inferred = thePlan.inferColumnCapabilities(ColumnType.STRING_ARRAY);
    Assert.assertNotNull(inferred);
    Assert.assertEquals(ColumnType.STRING_ARRAY, inferred.toColumnType());
    Assert.assertTrue(inferred.hasNulls().isMaybeTrue());
    Assert.assertFalse(inferred.isDictionaryEncoded().isMaybeTrue());
    Assert.assertFalse(inferred.areDictionaryValuesSorted().isMaybeTrue());
    Assert.assertFalse(inferred.areDictionaryValuesUnique().isMaybeTrue());
    Assert.assertTrue(inferred.hasMultipleValues().isTrue());
    Assert.assertFalse(inferred.hasBitmapIndexes());
    Assert.assertFalse(inferred.hasSpatialIndexes());

    Assert.assertEquals("array_append(\"scalar_string\", 'x')", thePlan.getAppliedExpression().stringify());
    Assert.assertEquals("array_append(\"scalar_string\", 'x')", thePlan.getAppliedFoldExpression("__acc").stringify());
    Assert.assertEquals(ExpressionType.STRING_ARRAY, thePlan.getOutputType());

    // multi-valued are cool too
    thePlan = plan("array_append(multi_dictionary_string, 'x')");
    assertArrayInAndOut(thePlan);

    // what about incomplete inputs with arrays? they are not reported as incomplete because they are treated as arrays
    thePlan = plan("array_append(string_unknown, 'x')");
    assertArrayInAndOut(thePlan);
    Assert.assertEquals(ExpressionType.STRING_ARRAY, thePlan.getOutputType());

    // what about if it is the scalar argument? there it is
    thePlan = plan("array_append(multi_dictionary_string, string_unknown)");
    Assert.assertTrue(
        thePlan.is(
            ExpressionPlan.Trait.NON_SCALAR_INPUTS,
            ExpressionPlan.Trait.INCOMPLETE_INPUTS,
            ExpressionPlan.Trait.NON_SCALAR_OUTPUT
        )
    );
    Assert.assertFalse(
        thePlan.is(
            ExpressionPlan.Trait.SINGLE_INPUT_SCALAR,
            ExpressionPlan.Trait.SINGLE_INPUT_MAPPABLE,
            ExpressionPlan.Trait.UNKNOWN_INPUTS,
            ExpressionPlan.Trait.NEEDS_APPLIED,
            ExpressionPlan.Trait.VECTORIZABLE
        )
    );
    // incomplete and unknown skip output type since we don't reliably know
    Assert.assertNull(thePlan.getOutputType());

    // array types are cool too
    thePlan = plan("array_append(string_array_1, 'x')");
    assertArrayInAndOut(thePlan);

    thePlan = plan("array_append(string_array_1, 'x')");
    assertArrayInAndOut(thePlan);
  }

  @Test
  public void testScalarOutputMultiValueInput()
  {
    ExpressionPlan thePlan = plan("array_to_string(array_append(scalar_string, 'x'), ',')");
    assertArrayInput(thePlan);
    ColumnCapabilities inferred = thePlan.inferColumnCapabilities(ColumnType.STRING);
    Assert.assertNotNull(inferred);
    Assert.assertEquals(ValueType.STRING, inferred.getType());
    Assert.assertTrue(inferred.hasNulls().isTrue());
    Assert.assertFalse(inferred.isDictionaryEncoded().isMaybeTrue());
    Assert.assertFalse(inferred.areDictionaryValuesSorted().isMaybeTrue());
    Assert.assertFalse(inferred.areDictionaryValuesUnique().isMaybeTrue());
    Assert.assertFalse(inferred.hasMultipleValues().isMaybeTrue());
    Assert.assertFalse(inferred.hasBitmapIndexes());
    Assert.assertFalse(inferred.hasSpatialIndexes());

    Assert.assertEquals(
        "array_to_string(array_append(\"scalar_string\", 'x'), ',')",
        thePlan.getAppliedExpression().stringify()
    );
    Assert.assertEquals(
        "array_to_string(array_append(\"scalar_string\", 'x'), ',')",
        thePlan.getAppliedFoldExpression("__acc").stringify()
    );
    Assert.assertEquals(ExpressionType.STRING, thePlan.getOutputType());

    // what about a multi-valued input
    thePlan = plan("array_to_string(array_append(scalar_string, multi_dictionary_string), ',')");
    assertArrayInput(thePlan);

    Assert.assertEquals(
        "array_to_string(map((\"multi_dictionary_string\") -> array_append(\"scalar_string\", \"multi_dictionary_string\"), \"multi_dictionary_string\"), ',')",
        thePlan.getAppliedExpression().stringify()
    );
    Assert.assertEquals(
        "array_to_string(fold((\"multi_dictionary_string\", \"scalar_string\") -> array_append(\"scalar_string\", \"multi_dictionary_string\"), \"multi_dictionary_string\", \"scalar_string\"), ',')",
        thePlan.getAppliedFoldExpression("scalar_string").stringify()
    );
    // why is this null
    Assert.assertEquals(ExpressionType.STRING, thePlan.getOutputType());
  }

  @Test
  public void testScalarOutputArrayInput()
  {
    ExpressionPlan thePlan = plan("array_to_string(array_append(string_array_1, 'x'), ',')");
    assertArrayInput(thePlan);

    Assert.assertEquals(
        "array_to_string(array_append(\"string_array_1\", 'x'), ',')",
        thePlan.getAppliedExpression().stringify()
    );
    Assert.assertEquals(
        "array_to_string(array_append(\"string_array_1\", 'x'), ',')",
        thePlan.getAppliedFoldExpression("__acc").stringify()
    );
    Assert.assertEquals(ExpressionType.STRING, thePlan.getOutputType());

    thePlan = plan("array_to_string(array_concat(string_array_1, string_array_2), ',')");
    assertArrayInput(thePlan);
    Assert.assertEquals(ExpressionType.STRING, thePlan.getOutputType());

    thePlan = plan("fold((x, acc) -> acc + x, array_concat(long_array_1, long_array_2), 0)");
    assertArrayInput(thePlan);
    Assert.assertEquals(
        "fold((\"x\", \"acc\") -> (\"acc\" + \"x\"), array_concat(\"long_array_1\", \"long_array_2\"), 0)",
        thePlan.getAppliedExpression().stringify()
    );
    Assert.assertEquals(
        "fold((\"x\", \"acc\") -> (\"acc\" + \"x\"), array_concat(\"long_array_1\", \"long_array_2\"), 0)",
        thePlan.getAppliedFoldExpression("__acc").stringify()
    );
    Assert.assertEquals(ExpressionType.LONG, thePlan.getOutputType());

    thePlan = plan("fold((x, acc) -> acc * x, array_concat(double_array_1, double_array_2), 0.0)");
    assertArrayInput(thePlan);
    Assert.assertEquals(
        "fold((\"x\", \"acc\") -> (\"acc\" * \"x\"), array_concat(\"double_array_1\", \"double_array_2\"), 0.0)",
        thePlan.getAppliedExpression().stringify()
    );
    Assert.assertEquals(
        "fold((\"x\", \"acc\") -> (\"acc\" * \"x\"), array_concat(\"double_array_1\", \"double_array_2\"), 0.0)",
        thePlan.getAppliedFoldExpression("__acc").stringify()
    );
    Assert.assertEquals(ExpressionType.DOUBLE, thePlan.getOutputType());
  }

  @Test
  public void testArrayConstruction()
  {
    ExpressionPlan thePlan = plan("array(long1, long2)");
    Assert.assertTrue(
        thePlan.is(
            ExpressionPlan.Trait.NON_SCALAR_OUTPUT
        )
    );
    Assert.assertFalse(
        thePlan.is(
            ExpressionPlan.Trait.SINGLE_INPUT_SCALAR,
            ExpressionPlan.Trait.SINGLE_INPUT_MAPPABLE,
            ExpressionPlan.Trait.UNKNOWN_INPUTS,
            ExpressionPlan.Trait.INCOMPLETE_INPUTS,
            ExpressionPlan.Trait.NEEDS_APPLIED,
            ExpressionPlan.Trait.NON_SCALAR_INPUTS,
            ExpressionPlan.Trait.VECTORIZABLE
        )
    );
    Assert.assertEquals(ExpressionType.LONG_ARRAY, thePlan.getOutputType());

    thePlan = plan("array(long1, double1)");
    Assert.assertEquals(ExpressionType.DOUBLE_ARRAY, thePlan.getOutputType());
    thePlan = plan("array(long1, double1, scalar_string)");
    Assert.assertEquals(ExpressionType.STRING_ARRAY, thePlan.getOutputType());
  }

  private static ExpressionPlan plan(String expression)
  {
    return ExpressionPlanner.plan(SYNTHETIC_INSPECTOR, Parser.parse(expression, TestExprMacroTable.INSTANCE));
  }

  private static void assertArrayInput(ExpressionPlan thePlan)
  {
    Assert.assertTrue(
        thePlan.is(
            ExpressionPlan.Trait.NON_SCALAR_INPUTS
        )
    );
    Assert.assertFalse(
        thePlan.is(
            ExpressionPlan.Trait.SINGLE_INPUT_SCALAR,
            ExpressionPlan.Trait.SINGLE_INPUT_MAPPABLE,
            ExpressionPlan.Trait.NON_SCALAR_OUTPUT,
            ExpressionPlan.Trait.INCOMPLETE_INPUTS,
            ExpressionPlan.Trait.UNKNOWN_INPUTS,
            ExpressionPlan.Trait.NEEDS_APPLIED,
            ExpressionPlan.Trait.VECTORIZABLE
        )
    );
  }

  private static void assertArrayInAndOut(ExpressionPlan thePlan)
  {
    Assert.assertTrue(
        thePlan.is(
            ExpressionPlan.Trait.NON_SCALAR_INPUTS,
            ExpressionPlan.Trait.NON_SCALAR_OUTPUT
        )
    );
    Assert.assertFalse(
        thePlan.is(
            ExpressionPlan.Trait.SINGLE_INPUT_SCALAR,
            ExpressionPlan.Trait.SINGLE_INPUT_MAPPABLE,
            ExpressionPlan.Trait.INCOMPLETE_INPUTS,
            ExpressionPlan.Trait.UNKNOWN_INPUTS,
            ExpressionPlan.Trait.NEEDS_APPLIED,
            ExpressionPlan.Trait.VECTORIZABLE
        )
    );
  }
}


text:
<!DOCTYPE html>

	<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
	<meta name="generator" content="ApiGen 2.8.0" />

	<title>Class LoggerLayoutSimple | Apache log4php</title>

	<link rel="stylesheet" type="text/css" media="all" href="resources/style.css?3505392360" />

		Overview

Packages

log4php

appenders

configurators

filters

helpers

layouts

pattern

renderers

Classes

LoggerLayoutHtml

LoggerLayoutPattern

LoggerLayoutSerialized

LoggerLayoutSimple

LoggerLayoutXml

	<form id="search">
		<input type="hidden" name="cx" value="" />
		<input type="hidden" name="ie" value="UTF-8" />
		<input type="text" name="q" class="text" />
		<input type="submit" value="Search" />
	</form>

				Overview

				Package

Class

				Tree

Class LoggerLayoutSimple

A simple layout.

Returns the log statement in a format consisting of the level,
followed by " - " and then the message.

For example the following php and properties files

{@example ../../examples/php/layout_simple.php 19}

{@example ../../examples/resources/layout_simple.properties 18}

would result in:

<samp>INFO - Hello World!</samp>

			LoggerConfigurable

			LoggerLayout

LoggerLayoutSimple

		Package: log4php\layouts

				Version:
				$Revision: 1213283 $

		Located at layouts/LoggerLayoutSimple.php

Methods summary

			 public
			string

		#
		format( LoggerLoggingEvent <var>$event</var> )

Returns the log statement in a format consisting of the level,
followed by " - " and then the message. For example, <samp> INFO - "A
message" </samp>

Returns the log statement in a format consisting of the level,
followed by " - " and then the message. For example, <samp> INFO - "A
message" </samp>

Parameters

<var>$event</var>

LoggerLoggingEvent
$event

Returns

					string

Overrides

LoggerLayout::format()

Methods inherited from LoggerLayout

			activateOptions(),
			getContentType(),
			getFooter(),
			getHeader(),
			warn()

Methods inherited from LoggerConfigurable

			setBoolean(),
			setFileSize(),
			setInteger(),
			setLevel(),
			setNumeric(),
			setPositiveInteger(),
			setString()

		Apache log4php API documentation generated by ApiGen 2.8.0


text:
package com.pipipark.spring.web.core.swagger;

import io.swagger.annotations.Api;

import java.util.ArrayList;
import java.util.HashSet;
import java.util.List;
import java.util.Set;

import org.springframework.context.annotation.Bean;
import org.springframework.http.MediaType;
import org.springframework.stereotype.Component;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.context.request.async.DeferredResult;

import springfox.documentation.builders.PathSelectors;
import springfox.documentation.builders.RequestHandlerSelectors;
import springfox.documentation.builders.ResponseMessageBuilder;
import springfox.documentation.service.ApiInfo;
import springfox.documentation.service.ApiKey;
import springfox.documentation.service.Contact;
import springfox.documentation.service.ResponseMessage;
import springfox.documentation.service.SecurityScheme;
import springfox.documentation.service.Tag;
import springfox.documentation.spi.DocumentationType;
import springfox.documentation.spring.web.plugins.Docket;
import springfox.documentation.swagger2.annotations.EnableSwagger2;

import com.pipipark.commons.PPPark;
import com.pipipark.scaner.PPParkScaner;
import com.pipipark.spring.web.core.manager.ConfigurationManager;
import com.pipipark.spring.web.core.model.BasicInfo;
import com.pipipark.spring.web.mvc.PPPMvcController;

@Component
@EnableSwagger2
public class Swagger2Configuration {

	@SuppressWarnings("rawtypes")
	@Bean
	public Docket api() {
		List<ResponseMessage> list = new ArrayList<ResponseMessage>();
		ResponseMessage success = new ResponseMessageBuilder().code(200).message("success").build();
		list.add(success);

		//请求和返回mime
		final Set<String> requestContentType = new HashSet<String>();
		requestContentType.add(MediaType.APPLICATION_JSON_VALUE);
		final Set<String> responseContentType = new HashSet<String>();
		responseContentType.add(MediaType.APPLICATION_JSON_VALUE);

		//获取基础配置中的扫描路径属性
		final BasicInfo basic = ConfigurationManager.getInstance().getBasicInfo();

		//API标签
		Set<Class> clazzs = PPParkScaner.getAllClass("com.pipipark.spring.web", basic.getScanerPackage());
		Tag firstTag = new Tag("Language", "语言功能");
		List<Tag> tags = new ArrayList<Tag>();
		for (Class<?> clazzType : clazzs) {
			if(PPPark.Array.contains(clazzType.getInterfaces(), PPPMvcController.class)){
				Api api = clazzType.getAnnotation(Api.class);
				if(api!=null){
					String key = api.tags()[0];
					String name = api.value();
					if(PPPark.String.isEmptyThereIsOne(key, name)){
						continue;
					}
					tags.add(new Tag(key, name));
				}
			}
		}

		//公共参数设置
		ApiKey commonsKey = new ApiKey("commonsKey", "commonsKey", "公共属性");
		List<SecurityScheme> keys = new ArrayList<SecurityScheme>();
		keys.add(commonsKey);

		Docket docket = new Docket(DocumentationType.SWAGGER_2)
				.genericModelSubstitutes(DeferredResult.class)
				.useDefaultResponseMessages(false)
				.forCodeGeneration(true)
				.select()
				.apis(RequestHandlerSelectors.any())
				.paths(PathSelectors.any())
				.build()
				.apiInfo(apiInfo(basic.getProjectName(), basic.settings().getSwagger().getContent()))
				.produces(requestContentType)
				.consumes(responseContentType)
//				.securitySchemes(keys)
				.tags(firstTag, tags.toArray(new Tag[0]))
				.globalResponseMessage(
						RequestMethod.GET,
						list);;

		return docket;
	}

	private ApiInfo apiInfo(String title, String custom) {
		Contact contact = new Contact("", "", "liuyunmoke@pipipark.com");
		ApiInfo apiInfo = new ApiInfo(title,
				"    本文档提供接口的对接规范,包括接口请求参数与返回值,错误对照表,加密规则等元素。\n"+
				"\r\n"+
				"###**Http状态码:**\n"+
				"<!--.info-->"+
				"**状态码** | **描述信息** | **备注** \n"+
				"----- | ----- | ----- \n"+
				"200 | success | 请求成功 \n"+
				"400 | parameter has wrong | 参数错误 \n"+
				"401 | not authorized | 未授权 \n"+
				"403 | refuse access | 拒绝访问 \n"+
				"404 | path is wrong | 地址错误 \n"+
				"500 | failure | 请求失败 \n"+
				"504 | timeout | 请求超时 \r\n"+
				"***"+
				"\r\n"+
				"###**业务码:**\n"+
				"<!--.info-->"+
				"**状态状态码** | **描述信息** | **备注** \n"+
				"----- | ----- | ----- \n"+
				"1000 | success | 业务请求成功 \n"+
				"20xx | failure | 业务请求失败 \n"+
				"***"+
				"\r\n"+
				"###**注意事项:**\n"+
				"    普通参数为选填参数。"+
				"\n"+
				"    粗体参数为必填参数。"+
				"\r\n"+
				"    上传图片,图片最大4096k。"+
				"\r\n"+
				(PPPark.String.isEmpty(custom)?"":custom)+
				"\r\n",
				"1.0",
				"www.pipipark.com",
				contact,
				"",
				"");
		return apiInfo;
	}
}


text:
get = require('../lib/index');

var argv = require('optimist')
        .usage('Usage: $0 [\'metric\', \'event\', \'types\'] [expression] {OPTIONS}')
        .wrap(80)
        .option('expression', {
          alias  : 'e',
          desc   : 'Expression to be evaluated by Cube evaluator'
        })
        .option('start', {
          alias  : 's',
          desc   : 'Start date of fetching. Can be a \'rendezvous\' expression'
        })
        .option('stop', {
          alias  : 'S',
          desc   : 'Stop date of fetching. Can be a \'rendezvous\' expression'
        })
        .option('over', {
          alias  : 'o',
          desc   : 'A \'rendezvous.duration\' expression. Time window over wich the event'+
                   ' or metric will be fetched. The missing start or stop option will be '+
                   'deduced from this'
        })
        .option('limit', {
          alias  : 'l',
          desc   : 'Maximum number of value to fetch. Can be a \'rendezvous.duration\' '+
                   'expression, the numeric value will be deduced from \'step\''
        })
        .option('step', {
          alias  : 't',
          desc   : 'Metric resolution exprimed as number or as \'rendezvous.duration\'. As '+
                   'reminder, Cube supports 5 resolutions : 10s, 1m, 5m, 1h and 1d',
          default : '10s'
        })
        .option('format', {
          alias  : 'f',
          desc   : 'Output format : pure json or csv',
          default: 'csv'
        })
        .option('json', {
          desc   : 'Shortcut for output format in pure json',
          boolean: true,
          default: false
        })
        .option('inverse', {
          alias  : 'i',
          desc   : 'Inverse date format in csv : mm/dd/yy to dd/mm/yy',
          boolean: true,
          default: false
        })
        .option('host', {
          alias  : 'H',
          desc   : 'Cube evaluator host',
          default: 'localhost:1081'
        })
        .option('request', {
          alias  : 'r',
          desc   : 'Only ouput the computed request without executing it',
          default: false,
          boolean: true
        })
        .option('help', {
          alias  : 'h',
          desc   : 'Display this message'
        })
        .check(function(argv) {
          if(argv.help) throw '';
          if(['types', 'metric', 'event'].indexOf(argv._[0] ) === -1)
            throw 'Specify \'types\', \'metric\' or \'event\'' ;
          if(argv._[1])
            argv.expression = argv._[1];
          if(argv.json)
            argv.format = 'json';
        })
        .argv;

switch(argv._[0]) {
  case 'types':
    if(argv.request)
      console.log(get.types.buildQuery(argv.host));
    else
      get.types(argv.host, function(arr) {
        return arr instanceof Error ? console.error(arr): console.log(arr.join('\n'));
      });
    break;

  case 'event':
    if(argv.request)
      console.log(get.event.buildQuery(argv.expression, argv).replace(/%3A/g, ':'));
    else
      get.event(argv.expression, argv, function(arr) {
        return arr instanceof Error ? console.error(arr): console.log(arr);
      });
      break;

  case 'metric':
    if(argv.request)
      console.log(get.metric.buildQuery(argv.expression, argv).replace(/%3A/g, ':'));
    else
      get.metric(argv.expression, argv, function(arr) {
        return arr instanceof Error ? console.error(arr): console.log(arr);
      });
    break;
}


text:
require 'ttfunk/reader'

module TTFunk
  class Table
    class Glyf
      class Compound
        include Reader

        ARG_1_AND_2_ARE_WORDS    = 0x0001
        WE_HAVE_A_SCALE          = 0x0008
        MORE_COMPONENTS          = 0x0020
        WE_HAVE_AN_X_AND_Y_SCALE = 0x0040
        WE_HAVE_A_TWO_BY_TWO     = 0x0080
        WE_HAVE_INSTRUCTIONS     = 0x0100

        attr_reader :raw
        attr_reader :x_min, :y_min, :x_max, :y_max
        attr_reader :glyph_ids

        Component = Struct.new(:flags, :glyph_index, :arg1, :arg2, :transform)

        def initialize(raw, x_min, y_min, x_max, y_max)
          @raw = raw
          @x_min, @y_min, @x_max, @y_max = x_min, y_min, x_max, y_max

          # Because TTFunk only cares about glyphs insofar as they (1) provide
          # a bounding box for each glyph, and (2) can be rewritten into a
          # font subset, we don't really care about the rest of the glyph data
          # except as a whole. Thus, we don't actually decompose the glyph
          # into it's parts--all we really care about are the locations within
          # the raw string where the component glyph ids are stored, so that
          # when we rewrite this glyph into a subset we can rewrite the
          # component glyph-ids so they are correct for the subset.

          @glyph_ids = []
          @glyph_id_offsets = []
          offset = 10 # 2 bytes for each of num-contours, min x/y, max x/y

          loop do
            flags, glyph_id = @raw[offset, 4].unpack("n*")
            @glyph_ids << glyph_id
            @glyph_id_offsets << offset + 2

            break unless flags & MORE_COMPONENTS != 0
            offset += 4

            if flags & ARG_1_AND_2_ARE_WORDS != 0
              offset += 4
            else
              offset += 2
            end

            if flags & WE_HAVE_A_TWO_BY_TWO != 0
              offset += 8
            elsif flags & WE_HAVE_AN_X_AND_Y_SCALE != 0
              offset += 4
            elsif flags & WE_HAVE_A_SCALE != 0
              offset += 2
            end
          end
        end

        def compound?
          true
        end

        def recode(mapping)
          result = @raw.dup
          new_ids = glyph_ids.map { |id| mapping[id] }

          new_ids.zip(@glyph_id_offsets).each do |new_id, offset|
            result[offset, 2] = [new_id].pack("n")
          end

          return result
        end
      end
    end
  end
end


text:
<?php

namespace Oro\IssueBundle\Tests\Unit\Form\Type;

use Doctrine\Common\Collections\ArrayCollection;
use Doctrine\ORM\Mapping\ClassMetadata;
use Oro\IssueBundle\Entity\Comment;
use Oro\IssueBundle\Entity\Issue;
use Oro\IssueBundle\Form\CommentType;
use Oro\IssueBundle\Form\IssueType;
use Symfony\Bridge\Doctrine\Form\Type\EntityType;
use Symfony\Component\Form\Extension\Validator\Type\FormTypeValidatorExtension;
use Symfony\Component\Form\FormBuilder;
use Symfony\Component\Form\Forms;
use Symfony\Component\Form\PreloadedExtension;
use Symfony\Component\Form\Test\TypeTestCase;
use Symfony\Component\Validator\ConstraintViolationList;

class CommentTypeTest extends TypeTestCase
{
    protected function setUp()
    {
        parent::setUp();

        $validator = $this->getMock('\Symfony\Component\Validator\ValidatorInterface');
        $validator->method('validate')->will($this->returnValue(new ConstraintViolationList()));

        $this->factory = Forms::createFormFactoryBuilder()
            ->addExtensions($this->getExtensions())
            ->addTypeExtension(
                new FormTypeValidatorExtension(
                    $validator
                )
            )
            ->addTypeGuesser(
                $this->getMockBuilder(
                    'Symfony\Component\Form\Extension\Validator\ValidatorTypeGuesser'
                )
                    ->disableOriginalConstructor()
                    ->getMock()
            )
            ->getFormFactory();

        $this->dispatcher = $this->getMock('Symfony\Component\EventDispatcher\EventDispatcherInterface');
        $this->builder = new FormBuilder(null, null, $this->dispatcher, $this->factory);
    }

    protected function getExtensions()
    {
        $mockEntityManager = $this->getMockBuilder('\Doctrine\ORM\EntityManager')
            ->disableOriginalConstructor()
            ->getMock();

        $mockRegistry = $this->getMockBuilder('Doctrine\Bundle\DoctrineBundle\Registry')
            ->disableOriginalConstructor()
            ->getMock();

        $mockRegistry->expects($this->any())->method('getManagerForClass')
            ->will($this->returnValue($mockEntityManager));

        $mockEntityManager ->expects($this->any())->method('getClassMetadata')
            ->withAnyParameters()
            ->will($this->returnValue(new ClassMetadata('entity')));

        $repository = $this->getMockBuilder('Doctrine\ORM\EntityRepository')
            ->disableOriginalConstructor()
            ->getMock();

        $mockEntityManager ->expects($this->any())->method('getRepository')
            ->withAnyParameters()
            ->will($this->returnValue($repository));

        $repository->expects($this->any())->method('findAll')
            ->withAnyParameters()
            ->will($this->returnValue(new ArrayCollection()));

        $entityType = new EntityType($mockRegistry);

        return array(new PreloadedExtension(array(
            'entity' => $entityType,
        ), array()));
    }

    public function testSubmitValidData()
    {
        $formData = array(
            'body' => 'test_body'
        );

        $repository = $this->getMockBuilder('Oro\IssueBundle\Entity\IssueRepository')
            ->disableOriginalConstructor()
            ->getMock();
        $type = new CommentType('test_action', $repository);
        $form = $this->factory->create($type);

        $commentEntity = new Comment();
        $commentEntity->setBody($formData['body']);

        // submit the data to the form directly
        $form->submit($formData);

        $this->assertTrue($form->isSynchronized());
        $this->assertEquals($commentEntity, $form->getData());

        $view = $form->createView();
        $children = $view->children;

        foreach (array_keys($formData) as $key) {
            $this->assertArrayHasKey($key, $children);
        }
    }
}


text:
//
//   Copyright 2015 Blu Age Corporation - Plano, Texas
//
//   Licensed under the Apache License, Version 2.0 (the "License");
//   you may not use this file except in compliance with the License.
//   You may obtain a copy of the License at
//
//       http://www.apache.org/licenses/LICENSE-2.0
//
//   Unless required by applicable law or agreed to in writing, software
//  distributed under the License is distributed on an "AS IS" BASIS,
//   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
//   See the License for the specific language governing permissions and
//   limitations under the License.
using System.Xml.Serialization;

namespace Summer.Batch.Core.Unity.Xml
{
    /// <summary>
    /// Xml representation of transition element.
    /// </summary>
    public abstract class XmlTransitionElement
    {
        /// <summary>
        /// on attribute.
        /// </summary>
        [XmlAttribute("on")]
        public string On { get; set; }
    }
}


text:
package com.dove.lib.oeb.ncx;

import android.os.Parcel;

import com.dove.lib.oeb.OEBContract;

/**
 * Created by george on 5/8/14.
 */
public class NavInfo extends DocElement {
    public NavInfo() {
        super();
    }

    public NavInfo(Parcel in, ClassLoader loader) {
        super(in, loader);
    }

    @Override
    protected String getElementName() {
        return OEBContract.Elements.NAV_INFO;
    }

    public static final ClassLoaderCreator<NavInfo> CREATOR = new ClassLoaderCreator<NavInfo>() {
        @Override
        public NavInfo createFromParcel(Parcel source, ClassLoader loader) {
            return new NavInfo(source, loader);
        }

        @Override
        public NavInfo createFromParcel(Parcel source) {
            return new NavInfo(source, null);
        }

        @Override
        public NavInfo[] newArray(int size) {
            return new NavInfo[size];
        }
    };
}