text:
import 'babel-core/polyfill';
import React,{ Component, PropTypes } from 'react';
import ReactDOM from 'react-dom';
//import BrowserHistory from 'react-router/lib/BrowserHistory';
import { Provider } from 'react-redux';
import { Router, Route } from 'react-router';
import configureStore from './store/configureStore';
import App from './containers/App';
import {compose, createStore, applyMiddleware } from 'redux';
// Redux DevTools store enhancers
import { devTools, persistState } from 'redux-devtools';
// React components for Redux DevTools
import { DevTools, DebugPanel, LogMonitor } from 'redux-devtools/lib/react';

const store = configureStore();

export default class Root extends Component {
  render() {
    // <DebugPanel top right bottom>
    //   <DevTools store={store} monitor={LogMonitor} />
    // </DebugPanel>
    return(
      <div>
        <Provider store={store}>
          <Router>
            <Route path="/" component={App}></Route>
          </Router>
        </Provider>
      </div>
    );
  }
}
ReactDOM.render(<Root />,document.getElementById('root'));


text:
class SessionsController < ApplicationController

  def new
    @student = Student.new
    @professor = Professor.new
  end

  def create
    @student = Student.find_by(email: params[:email])
    @professor = Professor.find_by(email: params[:email])
      if @student && @student.authenticate(params[:password])
        session[:student_id] = @student.id
        redirect_to @student
      elsif @professor && @professor.authenticate(params[:password])
        session[:professor_id] = @professor.id
        if is_admin?
          redirect_to '/admin/secr1t'
        else
          redirect_to @professor
        end
      else
        flash[:notice] = "Invalid email/password combination, please try again"
        render 'new'
      end
  end

  def destroy
    if is_student?
      session[:student_id] = nil
    else
      session[:professor_id] = nil
    end
    flash[:notice] = "Logged Out"
    redirect_to '/login'
  end

end

redpajama_set_name: RedPajamaGithub


text:
#ifndef _THEORY_DATATYPE_H_
#define _THEORY_DATATYPE_H_

#include"smt_theory.h"
#include"union_find.h"
#include"theory_datatype_params.h"
#include"datatype_decl_plugin.h"
#include"datatype_factory.h"

namespace smt {

    class theory_datatype : public theory {
        typedef trail_stack<theory_datatype> th_trail_stack;
        typedef union_find<theory_datatype>  th_union_find;

        struct var_data {
            ptr_vector<enode> m_recognizers; //!< recognizers of this equivalence class that are being watched.
            enode *           m_constructor; //!< constructor of this equivalence class, 0 if there is no constructor in the eqc.
            var_data():
                m_constructor(0) {
            }
        };

        struct stats {
            unsigned   m_occurs_check, m_splits;
            unsigned   m_assert_cnstr, m_assert_accessor;
            void reset() { memset(this, 0, sizeof(stats)); }
            stats() { reset(); }
        };

        theory_datatype_params &  m_params;
        datatype_util             m_util;
        ptr_vector<var_data>      m_var_data;
        th_union_find             m_find;
        th_trail_stack            m_trail_stack;
        datatype_factory *        m_factory;
        stats                     m_stats;

        bool is_constructor(app * f) const { return m_util.is_constructor(f); }
        bool is_recognizer(app * f) const { return m_util.is_recognizer(f); }
        bool is_accessor(app * f) const { return m_util.is_accessor(f); }

        bool is_constructor(enode * n) const { return is_constructor(n->get_owner()); }
        bool is_recognizer(enode * n) const { return is_recognizer(n->get_owner()); }
        bool is_accessor(enode * n) const { return is_accessor(n->get_owner()); }

        void assert_eq_axiom(enode * lhs, expr * rhs, literal antecedent);
        void assert_is_constructor_axiom(enode * n, func_decl * c, literal antecedent);
        void assert_accessor_axioms(enode * n);
        void add_recognizer(theory_var v, enode * recognizer);
        void propagate_recognizer(theory_var v, enode * r);
        void sign_recognizer_conflict(enode * c, enode * r);

        ptr_vector<enode>    m_to_unmark;
        svector<enode_pair>  m_used_eqs;
        enode *              m_main;
        bool occurs_check(enode * n);
        bool occurs_check_core(enode * n);

        void mk_split(theory_var v);

        void display_var(std::ostream & out, theory_var v) const;

    protected:
        virtual theory_var mk_var(enode * n);
        virtual bool internalize_atom(app * atom, bool gate_ctx);
        virtual bool internalize_term(app * term);
        virtual void apply_sort_cnstr(enode * n, sort * s);
        virtual void new_eq_eh(theory_var v1, theory_var v2);
        virtual bool use_diseqs() const;
        virtual void new_diseq_eh(theory_var v1, theory_var v2);
        virtual void assign_eh(bool_var v, bool is_true);
        virtual void relevant_eh(app * n);
        virtual void push_scope_eh();
        virtual void pop_scope_eh(unsigned num_scopes);
        virtual final_check_status final_check_eh();
        virtual void reset_eh();
        virtual bool is_shared(theory_var v) const;
    public:
        theory_datatype(ast_manager & m, theory_datatype_params & p);
        virtual ~theory_datatype();
        virtual theory * mk_fresh(context * new_ctx) { return alloc(theory_datatype, get_manager(), m_params); }
        virtual void display(std::ostream & out) const;
        virtual void collect_statistics(::statistics & st) const;
        virtual void init_model(model_generator & m);
        virtual model_value_proc * mk_value(enode * n, model_generator & m);
        th_trail_stack & get_trail_stack() { return m_trail_stack; }
        virtual void merge_eh(theory_var v1, theory_var v2, theory_var, theory_var);
        static void after_merge_eh(theory_var r1, theory_var r2, theory_var v1, theory_var v2) {}
        void unmerge_eh(theory_var v1, theory_var v2);
        virtual char const * get_name() const { return "datatype"; }
    };

};

#endif /* _THEORY_DATATYPE_H_ */


text:
using System;
using System.Runtime.Serialization;
using Gallio.Framework;
using Gallio.Model;

namespace Gallio.Framework.Assertions
{
    /// <summary>
    /// The exception type used by the Gallio assertion framework to signal assertion failures.
    /// </summary>
    [Serializable]
    public class AssertionException : TestFailedException
    {
        /// <summary>
        /// Creates an exception.
        /// </summary>
        public AssertionException()
        {
        }

        /// <summary>
        /// Creates an exception.
        /// </summary>
        /// <param name="message">The message.</param>
        public AssertionException(string message)
            : base(message)
        {
        }

        /// <summary>
        /// Creates an exception.
        /// </summary>
        /// <param name="message">The message.</param>
        /// <param name="innerException">The inner exception.</param>
        public AssertionException(string message, Exception innerException)
            : base(message, innerException)
        {
        }

        /// <summary>
        /// Creates an exception from serialization info.
        /// </summary>
        /// <param name="info">The serialization info.</param>
        /// <param name="context">The streaming context.</param>
        protected AssertionException(SerializationInfo info, StreamingContext context)
            : base(info, context)
        {
        }
    }
}


text:
package net.ros.client.gui;

import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.util.ResourceLocation;
import net.ros.client.gui.util.GuiMachineBase;
import net.ros.client.gui.util.GuiProgress;
import net.ros.client.gui.util.GuiTexturedSpace;
import net.ros.common.ROSConstants;
import net.ros.common.machine.module.impl.CraftingModule;
import net.ros.common.machine.module.impl.SteamModule;
import net.ros.common.tile.machine.TileRollingMill;

public class GuiRollingMill extends GuiMachineBase<TileRollingMill>
{
    public static final ResourceLocation BACKGROUND = new ResourceLocation(ROSConstants.MODID,
            "textures/gui/rollingmill.png");

    public GuiRollingMill(final EntityPlayer player, final TileRollingMill rollingmill)
    {
        super(player, rollingmill, BACKGROUND);

        this.addSteamTank(rollingmill.getModule(SteamModule.class)
                .getInternalSteamHandler(), 151, 7, 18, 73);
        this.addAnimatedSprite(rollingmill.getModule(CraftingModule.class)::getProgressScaled,
                GuiProgress.builder().space(GuiTexturedSpace.builder().x(79).y(34).width(25).height(16).u(176).v(14).s
                        (176 + 25).t(14 + 16).build()).direction(GuiProgress.StartDirection.RIGHT).revert(true)
                        .build());
    }
}


text:
<?xml version="1.0" encoding="utf-8" ?>
<data>
	<categories>
		<category>Bread</category>
		<category>Chutney</category>
		<category>Dessert</category>
		<category>Beverage</category>
		<category>Fish</category>
		<category>Poultry</category>
		<category>Vegetables</category>
		<category>Marinade</category>
		<category>Pasta</category>
		<category>Rice</category>
		<category>Salads</category>
		<category>Sauce</category>
		<category>Pork</category>
		<category>Venison</category>
	</categories>

	<recipe id="5">
		<category>Pasta</category>
		<title>RIBBON PASTA WITH MUSHROOMS AND TRUFFLE OIL</title>
		<smallimageurl>http://www.nicolasvahe.dk/resimgs/320PX/aw13_pasta.jpg</smallimageurl>
		<bigimageurl>http://www.nicolasvahe.dk/resimgs/960PX/aw13_pasta.jpg</bigimageurl>
		<description>Cut the bacon and mushrooms into thin strips and fry until crisp on an even heat. Add the cream and garlic appetizer. Boil until the sauce starts to thicken. Add salt to taste. Add the pasta to boiling, salted water and cook until al dente. Leave the pasta to drain in a colander. Then pour into the warm sauce in the pan. Mix well and sprinkle with finely grated parmesan. Finally, season the dish with freshly ground pepper and truffle oil and  garnish with parsley.</description>
		<time>45 min</time>
		<persons>4</persons>
		<ingredients>
			<item>1 bag of Nicolas Vahé Pasta / mushroom</item>
			<item>250 g mushrooms</item>
			<item>120 g bacon</item>
			<item>2 tsp Nicolas Vahé Appetizer / pure garlic</item>
			<item>30 cl whipping cream </item>
			<item>100 g grated parmesan</item>
			<item>4 tbsp Nicolas Vahé Truffle oil </item>
			<item>Nicolas Vahé Salt og Pepper / Everyday Mix</item>
			<item>Parsley </item>
		</ingredients>
		<nvproducts>
			<item>
				<productnumber>Nv0802</productnumber>
				<productdescription>Appetizer med Hvidløg</productdescription>
				<imageurl>http://appbilleder.housedoctor.dk/app/Nv0802.jpg</imageurl>
			</item>
			<item>
				<productnumber>Nv1004</productnumber>
				<productdescription>Fransk Havsalt</productdescription>
				<imageurl>http://appbilleder.housedoctor.dk/app/Nv1004.jpg</imageurl>
			</item>
			<item>
				<productnumber>Nv1005</productnumber>
				<productdescription>Sort Peber</productdescription>
				<imageurl>http://appbilleder.housedoctor.dk/app/Nv1005.jpg</imageurl>
			</item>
			<item>
				<productnumber>Nvlb02</productnumber>
				<productdescription>Tagliatelle med Karl Johan Svampe</productdescription>
				<imageurl>http://appbilleder.housedoctor.dk/app/Nvlb02.jpg</imageurl>
			</item>
			<item>
				<productnumber>Nvlp003</productnumber>
				<productdescription>Jomfru Olivenolie med Hvid Trøffel</productdescription>
				<imageurl>http://appbilleder.housedoctor.dk/app/Nvlp003.jpg</imageurl>
			</item>
		</nvproducts>
		<recipesurl>http://nicolasvahe.com/--/pasta/5</recipesurl>
	</recipe>

	<recipe id="6">
		<category>Risretter</category>
		<title>RISOTTO CROQUANT</title>
		<smallimageurl>http://www.nicolasvahe.dk/resimgs/320PX/aw13_krokant.jpg</smallimageurl>
		<bigimageurl>http://www.nicolasvahe.dk/resimgs/960PX/aw13_krokant.jpg</bigimageurl>
		<description>Prepare the risotto by following the instructions on the bag. Leave to cool.  Fry the onion and ham on a hot pan with some olive oil until golden. Add the diced mozzarella, fried onion and ham to the cold risotto and season  with salt and pepper. Then roll the risotto into small, round balls and bread them by coating them in whipped whole eggs, flour and breadcrumbs. Deep-fry the balls in oil at 180 C until golden. This takes approx. 3-4 minutes. Serve on frisée lettuce seasoned with walnut oil and truffle glaze.</description>
		<time>60 min</time>
		<persons>6</persons>
		<ingredients>
			<item>1 bag Nicolas Vahé Risotto / mushroom</item>
			<item>100 g diced Parma ham</item>
			<item>100 g fresh, diced mozzarella</item>
			<item>50 g finely chopped onion</item>
			<item>2 eggs</item>
			<item>200 g breadcrumbs</item>
			<item>100 g flour</item>
			<item>Nicolas Vahé Extra virgin olive oil </item>
			<item>Salt and pepper </item>
			<item>Frisee salad</item>
			<item>Nicolas Vahé Walnut oil</item>
			<item>Nicolas Vahé Glaze / truffle</item>
		</ingredients>
		<nvproducts>
			<item>
				<productnumber>Nv1004</productnumber>
				<productdescription>Fransk Havsalt</productdescription>
				<imageurl>http://appbilleder.housedoctor.dk/app/Nv1004.jpg</imageurl>
			</item>
			<item>
				<productnumber>Nv1005</productnumber>
				<productdescription>Sort Peber</productdescription>
				<imageurl>http://appbilleder.housedoctor.dk/app/Nv1005.jpg</imageurl>
			</item>
			<item>
				<productnumber>Nval060</productnumber>
				<productdescription>Glaze med Trøffel</productdescription>
				<imageurl>http://appbilleder.housedoctor.dk/app/Nval060.jpg</imageurl>
			</item>
			<item>
				<productnumber>Nvfm02</productnumber>
				<productdescription>Risotto med Svampe</productdescription>
				<imageurl>http://appbilleder.housedoctor.dk/app/Nvfm02.jpg</imageurl>
			</item>
			<item>
				<productnumber>Nvlp005</productnumber>
				<productdescription>Valnøddeolie</productdescription>
				<imageurl>http://appbilleder.housedoctor.dk/app/Nvlp005.jpg</imageurl>
			</item>
			<item>
				<productnumber>Nvlp020</productnumber>
				<productdescription>Ekstra Jomfru Olivenolie</productdescription>
				<imageurl>http://appbilleder.housedoctor.dk/app/Nvlp020.jpg</imageurl>
			</item>
		</nvproducts>
		<recipesurl>http://nicolasvahe.com/--/rice/6</recipesurl>
	</recipe>

	<recipe id="7">
		<category>Chutney</category>
		<title>APRICOT AND DATE CHUTNEY WITH PISTACHIO OIL</title>
		<smallimageurl>http://www.nicolasvahe.dk/resimgs/320PX/aw13_olie3.jpg</smallimageurl>
		<bigimageurl>http://www.nicolasvahe.dk/resimgs/960PX/aw13_olie3.jpg</bigimageurl>
		<description>Cut the apricots, dates, onion and garlic into small pieces. Pour sugar and honey into a pan and caramelise until golden. Carefully add balsamic vinegar and lemon juice and boil for 2-3 minutes with the vanilla bean, pepper and cinnamon stick. Add the apricots, dates, onion and garlic and simmer for approx. 30 minutes at low heat. Leave to cool and finally add pistachio oil. Store cool in a tightly closed container and serve within 8 days. Enjoy the chutney with e.g. cheese or paté.</description>
		<time>60 min</time>
		<persons>4</persons>
		<ingredients>
			<item>125 g apricots</item>
			<item>125 g dates</item>
			<item>1 onion</item>
			<item>1 clove of garlic</item>
			<item>50 g sugar</item>
			<item>25 g Nicolas Vahé Honey / lemon</item>
			<item>1 dl Nicolas Vahé White wine vinegar / Aceto Balsamico</item>
			<item>Juice of 1 lemon</item>
			<item>50 cl Nicolas Vahé Pistachio oil</item>
			<item>1 vanilla pod</item>
			<item>1 Nicolas Vahé Cinnamon stick</item>
			<item>Freshly ground pepper</item>
		</ingredients>
		<nvproducts>
			<item>
				<productnumber>Nv1202</productnumber>
				<productdescription>Hvid Balsamico</productdescription>
				<imageurl>http://appbilleder.housedoctor.dk/app/Nv1202.jpg</imageurl>
			</item>
			<item>
				<productnumber>Nvap02</productnumber>
				<productdescription>Honning med Citron</productdescription>
				<imageurl>http://appbilleder.housedoctor.dk/app/Nvap02.jpg</imageurl>
			</item>
			<item>
				<productnumber>Nvkm07</productnumber>
				<productdescription>Kanelstænger</productdescription>
				<imageurl>http://appbilleder.housedoctor.dk/app/Nvkm07.jpg</imageurl>
			</item>
			<item>
				<productnumber>Nvlp002</productnumber>
				<productdescription>Olie med Pistacie</productdescription>
				<imageurl>http://appbilleder.housedoctor.dk/app/Nvlp002.jpg</imageurl>
			</item>
		</nvproducts>
		<recipesurl>http://nicolasvahe.com/--/chutney/7</recipesurl>
	</recipe>

	<recipe id="8">
		<category>Grøntsager</category>
		<title>OVEN-BAKED ARTICHOKES</title>
		<smallimageurl>http://www.nicolasvahe.dk/resimgs/320PX/aw13_olie1.jpg</smallimageurl>
		<bigimageurl>http://www.nicolasvahe.dk/resimgs/960PX/aw13_olie1.jpg</bigimageurl>
		<description>crub the artichokes and place them in an ovenproof dish. Add hazelnut oil and salt. Bake them in the oven at 180 C for 20-25 minutes, depending on the size of the artichokes. When ready, coat them in as much pesto as you want. Finish with grated parmesan.</description>
		<time>45 min</time>
		<persons>4</persons>
		<ingredients>
			<item>600 g fresh artichokes</item>
			<item>Nicolas Vahé Hazelnut oil</item>
			<item>Nicolas Vahé Salt / parmesan og basil</item>
			<item>50 g freshly grated parmesan</item>
			<item>Nicolas Vahé Pesto / green olives og fennel or tomato og artichoke  </item>
		</ingredients>
		<nvproducts>
			<item>
				<productnumber>Nv0706</productnumber>
				<productdescription>Pesto med Tomat og Artiskok</productdescription>
				<imageurl>http://appbilleder.housedoctor.dk/app/Nv0706.jpg</imageurl>
			</item>
			<item>
				<productnumber>Nv0711             </productnumber>
				<productdescription>Pesto med Grønne Oliven og Fennikel</productdescription>
				<imageurl>http://appbilleder.housedoctor.dk/app/Nv0711.jpg</imageurl>
			</item>
			<item>
				<productnumber>Nv1000</productnumber>
				<productdescription>Salt med Parmesan Ost og Basilikum</productdescription>
				<imageurl>http://appbilleder.housedoctor.dk/app/Nv1000.jpg</imageurl>
			</item>
			<item>
				<productnumber>Nvlp004</productnumber>
				<productdescription>Hasselnøddeolie</productdescription>
				<imageurl>http://appbilleder.housedoctor.dk/app/Nvlp004.jpg</imageurl>
			</item>
		</nvproducts>
		<recipesurl>http://nicolasvahe.com/--/vegetables/8</recipesurl>
	</recipe>

	<recipe id="12">
		<category>Dessert</category>
		<title>APPLE CRUMBLE WITH CRéME FRAICHE
AND WHITE PUNCH</title>
		<smallimageurl>http://www.nicolasvahe.dk/resimgs/320PX/aw13_apple_crumble.jpg</smallimageurl>
		<bigimageurl>http://www.nicolasvahe.dk/resimgs/960PX/aw13_apple_crumble.jpg</bigimageurl>
		<description>Peel and dice the apples. Coat in pistachio curd and place in a tart mould with a diameter of approx. 25 cm. Grate the marzipan with a grater and sprinkle over the apples. Mix the oats, butter, sugar and vanilla from 1 vanilla pod in a food processor until the mixture has a crumb-like consistency. Top the apples with the mixture and bake the cake for approx. 30 minutes at 200 C. Serve the dish warm with crème fraiche mixed with Nicolas Vahé white punch extract.</description>
		<time>60 min </time>
		<persons>4</persons>
		<ingredients>
			<item>1/2 kg apples</item>
			<item>1 tbsp Nicolas Vahé Curd / pistachio</item>
			<item>150 g marzipan</item>
			<item>25 cl rolled oats </item>
			<item>75 g soft butter</item>
			<item>150 g sugar</item>
			<item>1 vanilla pod  </item>
			<item>5 cl Nicolas Vahé White Punch</item>
			<item>8 tbsp creme fraiche 38% </item>
		</ingredients>
		<nvproducts>
			<item>
				<productnumber>Nv0323</productnumber>
				<productdescription>Marmelade med Pistaciecreme</productdescription>
				<imageurl>http://appbilleder.housedoctor.dk/app/Nv0323.jpg</imageurl>
			</item>
			<item>
				<productnumber>Nv1090</productnumber>
				<productdescription>Gløgg Ekstrakt, Hvid, 25 cl.</productdescription>
				<imageurl>http://appbilleder.housedoctor.dk/app/Nv1090.jpg</imageurl>
			</item>
		</nvproducts>
		<recipesurl>http://nicolasvahe.com/--/dessert/12</recipesurl>
	</recipe>

	<recipe id="23">
		<category>Brød</category>
		<title>PESTO BREAD </title>
		<smallimageurl>http://www.nicolasvahe.dk/resimgs/320PX/ss13_broed.jpg</smallimageurl>
		<bigimageurl>http://www.nicolasvahe.dk/resimgs/960PX/ss13_broed.jpg</bigimageurl>
		<description>Stir the tepid water, sugar, yeast, salt and pesto together in a bowl. Add the flour and knead the dough well for approx. 14 minutes in a mixer.  Allow the dough to rest in the bowl for 40 minutes at room temperature. Knead the dough by hand into a ball, and set aside in a dough rising basket sprinkled with plenty of flour. Allow to rise for 1 hour. Pre-heat the oven to 250 C. Place an ovenproof dish in the bottom of the oven. Carefully turn the dough onto a warm baking plate covered with  greaseproof paper. Put the bread in the oven, and pour approx. 1 dl of water into the ovenproof dish. Quickly close the oven to avoid the steam escaping. Bake at 250 C for 5 minutes. Then turn the oven down to 200 C. Bake the bread for approx. 30 minutes until a crisp crust appears.</description>
		<time>150 min</time>
		<persons>6</persons>
		<ingredients>
			<item>2 loaves</item>
			<item></item>
			<item>1 kg wheat flour</item>
			<item>6 dl tepid water</item>
			<item>40 g fresh yeast </item>
			<item>25 g Nicolas Vahé French Sea Salt</item>
			<item>10 g sugar</item>
			<item>Your favourite Nicolas Vahé Pesto</item>
		</ingredients>
		<nvproducts>
			<item>
				<productnumber>Nv0711</productnumber>
				<productdescription>Pesto med Grønne Oliven og Fennikel</productdescription>
				<imageurl>http://appbilleder.housedoctor.dk/app/Nv0711.jpg</imageurl>
			</item>
			<item>
				<productnumber>Nv1006</productnumber>
				<productdescription>Fransk Salt i pose</productdescription>
				<imageurl>http://appbilleder.housedoctor.dk/app/Nv1006.jpg</imageurl>
			</item>
		</nvproducts>
		<recipesurl>http://nicolasvahe.com/--/bread/23</recipesurl>
	</recipe>

	<recipe id="29">
		<category>Brød</category>
		<title>OLIVE AND FETA CHEESE CAKE</title>
		<smallimageurl>http://www.nicolasvahe.dk/resimgs/320PX/ss13_olivenbrod.jpg</smallimageurl>
		<bigimageurl>http://www.nicolasvahe.dk/resimgs/960PX/ss13_olivenbrod.jpg</bigimageurl>
		<description>Pre-heat the oven to 180 C. Mix flour and baking powder in a bowl. Make a hollow in the middle and add the eggs and oil. Pour the cream into the flour mixture. Whisk everything thoroughly together. Dice the feta cheese and add cheese, pesto and a little salt and pepper to the  mixture. Mix well. Grease a bread tin with butter and pour in the dough. Serve the cake hot or cold. Bake the cake in the oven for approx. 40 minutes. Leave to cool. It tastes fantastic with different types of pesto. Serve with aperitifs or add a special twist to your dinner.</description>
		<time>60 min</time>
		<persons>6</persons>
		<ingredients>
			<item>200 g flour</item>
			<item>1 tsp baking powder</item>
			<item>3 eggs</item>
			<item>1 dl Nicolas Vahé Olive oil / garlic</item>
			<item>1 dl whipped cream</item>
			<item>200 g feta cheese </item>
			<item>2 tbsp Nicolas Vahé Pesto / olive og almond  </item>
			<item>25 g soft butter</item>
			<item>Nicolas Vahé French Sea Salt</item>
			<item>Nicolas Vahé Pepper / The Mixed Blend</item>
		</ingredients>
		<nvproducts>
			<item>
				<productnumber>Nv0708</productnumber>
				<productdescription>Pesto med Oliven og Mandel</productdescription>
				<imageurl>http://appbilleder.housedoctor.dk/app/Nv0708.jpg</imageurl>
			</item>
			<item>
				<productnumber>Nv1004</productnumber>
				<productdescription>Fransk Havsalt</productdescription>
				<imageurl>http://appbilleder.housedoctor.dk/app/Nv1004.jpg</imageurl>
			</item>
			<item>
				<productnumber>Nv1005</productnumber>
				<productdescription>Sort Peber</productdescription>
				<imageurl>http://appbilleder.housedoctor.dk/app/Nv1005.jpg</imageurl>
			</item>
			<item>
				<productnumber>Nv1100</productnumber>
				<productdescription>Olivenolie med Hvidløg</productdescription>
				<imageurl>http://appbilleder.housedoctor.dk/app/Nv1100.jpg</imageurl>
			</item>
		</nvproducts>
		<recipesurl>http://nicolasvahe.com/--/bread/29</recipesurl>
	</recipe>

	<recipe id="30">
		<category>Grøntsager</category>
		<title>FARCIES - SOUTHERN FRENCH VEGETABLE DISH</title>
		<smallimageurl>http://www.nicolasvahe.dk/resimgs/320PX/ss13_fyldte grontsag.jpg</smallimageurl>
		<bigimageurl>http://www.nicolasvahe.dk/resimgs/960PX/ss13_fyldte grontsag.jpg</bigimageurl>
		<description>Cut the top off the tomatoes and scoop out the flesh. Set aside the flesh in a bowl. Sprinkle salt inside the tomatoes and place them on a paper towel to drip. Cut the peppers in halves and remove stalks and seeds. Mix the pork and veal with the onions, eggs, fresh herbs, garlic appetizer, salt and pepper. Add the flesh of the tomatoes and leave to rest in the refrigerator. Stuff the vegetables with the mince, and bake them in the oven at 180 C for approx. 30 minutes. Keep an eye on the vegetables as the exact cooking time depends on the size of the vegetables. Serve with warm bread, a green salad, and marinated meat on skewers.</description>
		<time>60 min </time>
		<persons>4</persons>
		<ingredients>
			<item>4 beef tomatoes</item>
			<item>4 red peppers</item>
			<item>4 yellow peppers</item>
			<item>400 g minced veal </item>
			<item>200 g minced pork</item>
			<item>2 small chopped onions</item>
			<item>2 fresh eggs</item>
			<item>Fresh parsley and thyme</item>
			<item>2 tsp Nicolas Vahé Appetizer / pure garlic</item>
			<item>Nicolas Vahé Pepper / The Mixed Blend</item>
			<item>Nicolas Vahé Salt / parmesan og basil</item>
			<item> Nicolas Vahé Extra virgin olive oil</item>
			<item></item>
		</ingredients>
		<nvproducts>
			<item>
				<productnumber>Nv0802</productnumber>
				<productdescription>Appetizer med Hvidløg</productdescription>
				<imageurl>http://appbilleder.housedoctor.dk/app/Nv0802.jpg</imageurl>
			</item>
			<item>
				<productnumber>Nv1000</productnumber>
				<productdescription>Salt med Parmesan Ost og Basilikum</productdescription>
				<imageurl>http://appbilleder.housedoctor.dk/app/Nv1000.jpg</imageurl>
			</item>
			<item>
				<productnumber>Nv1005</productnumber>
				<productdescription>Sort Peber</productdescription>
				<imageurl>http://appbilleder.housedoctor.dk/app/Nv1005.jpg</imageurl>
			</item>
			<item>
				<productnumber>Nvlp020</productnumber>
				<productdescription>Ekstra Jomfru Olivenolie</productdescription>
				<imageurl>http://appbilleder.housedoctor.dk/app/Nvlp020.jpg</imageurl>
			</item>
		</nvproducts>
		<recipesurl>http://nicolasvahe.com/--/vegetables/30</recipesurl>
	</recipe>

	<recipe id="36">
		<category>Grøntsager</category>
		<title>TOMATO SNACKS</title>
		<smallimageurl>http://www.nicolasvahe.dk/resimgs/320PX/NV.tomatsnack.jpg</smallimageurl>
		<bigimageurl>http://www.nicolasvahe.dk/resimgs/960PX/NV.tomatsnack.jpg</bigimageurl>
		<description>Cut out 10 circles from the puff pastry, using a glass or a round pastry cutter. Place them on a sheet of baking paper and spread with pesto. Place a cherry tomato on top and sprinkle with salt, pepper and olive oil. Bake at 220 C for about 10 minutes. Sprinkle with finely chopped thyme and rosemary and serve while warm.</description>
		<time>15 min</time>
		<persons>4</persons>
		<ingredients>
			<item>1 roll puff pastry</item>
			<item>1 glass Nicolas Vahé Pesto / pure tomato</item>
			<item>10 large cherry tomatoes</item>
			<item>Olive oil</item>
			<item>Salt and pepper</item>
			<item>Thyme</item>
			<item>Rosemary</item>
			<item></item>
		</ingredients>
		<nvproducts>
			<item>
				<productnumber>Nv0700</productnumber>
				<productdescription>Pesto med Tomat</productdescription>
				<imageurl>http://appbilleder.housedoctor.dk/app/Nv0700.jpg</imageurl>
			</item>
		</nvproducts>
		<recipesurl>http://nicolasvahe.com/--/vegetables/36</recipesurl>
	</recipe>

	<recipe id="44">
		<category>Brød</category>
		<title>BRUSCHETTA</title>
		<smallimageurl>http://www.nicolasvahe.dk/resimgs/320PX/opskrifter.17.2.jpg</smallimageurl>
		<bigimageurl>http://www.nicolasvahe.dk/resimgs/960PX/opskrifter.17.2.jpg</bigimageurl>
		<description>Dissolve yeast and salt in the lukewarm water. Slowly work the flour into the liquid; use the dough hook on your hand mixer or knead the  dough by hand for about 5 min. Then leave the dough covered in a warm  place for 11/2 hours. Sprinkle flour on your worktop and roll out the dough into a square that measures 30x40 cm and which is about 2 cm thick. Spread pesto and sprinkle the Herbes de Provence over the dough. Drizzle the dough with Nicolas Vahé Olive oil with garlic. Close the bread from the left and cover the right-hand side. Brush the  edges with water, and press the bread together at the sides using a fork. Finally, brush the bread with Nicolas Vahé Olive oil and sprinkle with  Herbes de Provence. Make cuts at a slant every 2 cm, so that the filling  inside is visible. Bake the bread for about 30 min. at 180 C, or until the bread has a crisp crust.</description>
		<time>120 min</time>
		<persons>4</persons>
		<ingredients>
			<item>3.5 dl water</item>
			<item>40 g fresh yeast</item>
			<item>650 g plain flour</item>
			<item>1 tsp coarse salt</item>
			<item>150 g Nicolas Vahé Pesto / black olive og basil </item>
			<item>1 tsp Herbes de Provence </item>
			<item>6 tbsp Nicolas Vahé Oil / garlic</item>
			<item></item>
			<item></item>
		</ingredients>
		<nvproducts>
			<item>
				<productnumber>Nv0705</productnumber>
				<productdescription>Pesto med Sorte Oliven og Basilikum</productdescription>
				<imageurl>http://appbilleder.housedoctor.dk/app/Nv0705.jpg</imageurl>
			</item>
			<item>
				<productnumber>Nv1100</productnumber>
				<productdescription>Olivenolie med Hvidløg</productdescription>
				<imageurl>http://appbilleder.housedoctor.dk/app/Nv1100.jpg</imageurl>
			</item>
		</nvproducts>
		<recipesurl>http://nicolasvahe.com/--/bread/44</recipesurl>
	</recipe>

	<recipe id="48">
		<category>Saucer</category>
		<title>KETCHUP A LA NICOLAS (250 ml)</title>
		<smallimageurl>http://www.nicolasvahe.dk/resimgs/320PX/opskrifter.9.2.jpg</smallimageurl>
		<bigimageurl>http://www.nicolasvahe.dk/resimgs/960PX/opskrifter.9.2.jpg</bigimageurl>
		<description>Cut tomatoes, onion and garlic into smaller pieces. Let them simmer in a  saucepan at low heat for 30 min. Blend the mixture until it is smooth, and add  the two types of vinegar. Put the saucepan back on the heat and allow the  mixture to simmer until it has reduced to half the amount (about 45 min. at  low heat). Stir the mixture until it is even, and then strain it. Add salt, pepper, sugar  and lemon juice. Reduce the mixture for the last time to half the amount over  a low heat, until it gains a nice, smooth consistency. Pour the homemade  ketchup into a bottle or a jar that can be closed tightly, and leave it in  the refrigerator. The ketchup will be ready for use after 2-3 days and will keep for about two weeks in the refrigerator.</description>
		<time>120 min</time>
		<persons>4</persons>
		<ingredients>
			<item>1 kg tomatoes</item>
			<item>1 onion</item>
			<item>3 garlic cloves</item>
			<item>5 dl Nicolas Vahé Red wine vinegar / raspberry</item>
			<item>2.5 dl Nicolas Vahé Red wine vinegar / Aceto balsamico di Modena</item>
			<item>50 g sugar</item>
			<item>Salt and pepper</item>
			<item>1 tsp lemon juice</item>
		</ingredients>
		<nvproducts>
			<item>
				<productnumber>Nv1004</productnumber>
				<productdescription>Fransk Havsalt</productdescription>
				<imageurl>http://appbilleder.housedoctor.dk/app/Nv1004.jpg</imageurl>
			</item>
			<item>
				<productnumber>Nv1005</productnumber>
				<productdescription>Sort Peber</productdescription>
				<imageurl>http://appbilleder.housedoctor.dk/app/Nv1005.jpg</imageurl>
			</item>
			<item>
				<productnumber>Nv1200</productnumber>
				<productdescription>Rødvinseddike med Hindbær</productdescription>
				<imageurl>http://appbilleder.housedoctor.dk/app/Nv1200.jpg</imageurl>
			</item>
			<item>
				<productnumber>Nv1201</productnumber>
				<productdescription>Rødvinseddike - Aceto Balsamico di Modena</productdescription>
				<imageurl>http://appbilleder.housedoctor.dk/app/Nv1201.jpg</imageurl>
			</item>
		</nvproducts>
		<recipesurl>http://nicolasvahe.com/--//48</recipesurl>
	</recipe>

	<recipe id="57">
		<category>Gris</category>
		<title>BAKED GOATS CHEESE IN BACON</title>
		<smallimageurl>http://www.nicolasvahe.dk/resimgs/320PX/NV.opskrift.7.2.jpg</smallimageurl>
		<bigimageurl>http://www.nicolasvahe.dk/resimgs/960PX/NV.opskrift.7.2.jpg</bigimageurl>
		<description>Cut the cheese into pieces of around 50 g each and roll a piece of bacon around each piece of cheese. Finely dice the apple. Make a dressing of balsamico, mustard, olive oil and orange juice and add the diced apple. Place the salad leaves in the dressing and toss.Fry the cheese in a hot  pan until the bacon is crisp. Serve with salad.</description>
		<time>30 min</time>
		<persons>4</persons>
		<ingredients>
			<item>400 g firm goats cheese</item>
			<item>8 slices of bacon</item>
			<item>1 apple</item>
			<item>300 g mixed salad leaves</item>
			<item>5 tsp Nicolas Vahé Red wine vinegar / Aceto balsamico de Modena</item>
			<item>2 tsp Nicolas Vahé Mustard / raspberry og ginger, 190 g</item>
			<item>3 tbsp orange juice</item>
			<item>6 tbsp Nicolas Vahé Olive oil / basil </item>
		</ingredients>
		<nvproducts>
			<item>
				<productnumber>Nv1050</productnumber>
				<productdescription>Sennep med Hindbær og Ingefær</productdescription>
				<imageurl>http://appbilleder.housedoctor.dk/app/Nv1050.jpg</imageurl>
			</item>
			<item>
				<productnumber>Nv1104</productnumber>
				<productdescription>Olivenolie med Basilikum</productdescription>
				<imageurl>http://appbilleder.housedoctor.dk/app/Nv1104.jpg</imageurl>
			</item>
			<item>
				<productnumber>Nv1201</productnumber>
				<productdescription>Rødvinseddike - Aceto Balsamico di Modena</productdescription>
				<imageurl>http://appbilleder.housedoctor.dk/app/Nv1201.jpg</imageurl>
			</item>
		</nvproducts>
		<recipesurl>http://nicolasvahe.com/--//57</recipesurl>
	</recipe>

	<recipe id="58">
		<category>Marinade</category>
		<title>BAKED POTATOES WITH PESTO AND HERBE</title>
		<smallimageurl>http://www.nicolasvahe.dk/resimgs/320PX/NV.opskrift.4.2.jpg</smallimageurl>
		<bigimageurl>http://www.nicolasvahe.dk/resimgs/960PX/NV.opskrift.4.2.jpg</bigimageurl>
		<description>Finely chop garlic and herbs. Place all the ingredients for the marinade in a bowl and mix using your hands. Take a small piece of baking paper, place two potatoes in the middle and pour a tablespoon of the marinade over. Then gather  the paper together to form a bag and tie with a small piece of meat string.  Create three more packages. Garnish with sprigs of rosemary or thyme. Bake in  the oven for 8 min. at 180 C or 8 min. under the grill.</description>
		<time>45 min</time>
		<persons>2</persons>
		<ingredients>
			<item>8 small, cooked potatoes </item>
			<item>Marinade: </item>
			<item>100 g Nicolas Vahé Pesto / black olives og basil </item>
			<item>3 spsk Nicolas Vahé Olive oil / lemon</item>
			<item>2 cloves garlic </item>
			<item>Sprigs of thyme and rosemary </item>
			<item>Salt and pepper</item>
		</ingredients>
		<nvproducts>
			<item>
				<productnumber>Nv0705</productnumber>
				<productdescription>Pesto med Sorte Oliven og Basilikum</productdescription>
				<imageurl>http://appbilleder.housedoctor.dk/app/Nv0705.jpg</imageurl>
			</item>
			<item>
				<productnumber>Nv1004</productnumber>
				<productdescription>Fransk Havsalt</productdescription>
				<imageurl>http://appbilleder.housedoctor.dk/app/Nv1004.jpg</imageurl>
			</item>
			<item>
				<productnumber>Nv1005</productnumber>
				<productdescription>Sort Peber</productdescription>
				<imageurl>http://appbilleder.housedoctor.dk/app/Nv1005.jpg</imageurl>
			</item>
			<item>
				<productnumber>Nv1105</productnumber>
				<productdescription>Olivenolie med Lemon</productdescription>
				<imageurl>http://appbilleder.housedoctor.dk/app/Nv1105.jpg</imageurl>
			</item>
			<item>
				<productnumber>Nvkm03</productnumber>
				<productdescription>Rosmarin</productdescription>
				<imageurl>http://appbilleder.housedoctor.dk/app/Nvkm03.jpg</imageurl>
			</item>
			<item>
				<productnumber>Nvkm06</productnumber>
				<productdescription>Timian</productdescription>
				<imageurl>http://appbilleder.housedoctor.dk/app/Nvkm06.jpg</imageurl>
			</item>
		</nvproducts>
		<recipesurl>http://nicolasvahe.com/--/marinade/58</recipesurl>
	</recipe>

	<recipe id="59">
		<category>Grøntsager</category>
		<title>BRUSCETTA A LA NICOLAS</title>
		<smallimageurl>http://www.nicolasvahe.dk/resimgs/320PX/NV.opskrift.5.2.jpg</smallimageurl>
		<bigimageurl>http://www.nicolasvahe.dk/resimgs/960PX/NV.opskrift.5.2.jpg</bigimageurl>
		<description>CRUMBLE THE FETA CHEESE USING A FORK. ADD THE QUARK AND SEASON WITH SALT AND PEPPER. DRIZZLE THE SLICES OF BREAD WITH NICOLAS VAHé OLIVE OIL AND SPRINKLE WITH FINELY-CHOPPED GARLIC. TOAST THE BREAD IN THE MIDDLE OF THE OVEN FOR 5 MIN. AT 220 C UNTIL GOLDEN AND CRISP ON TOP. SPREAD A LAYER OF PESTO ON THE BREAD AND TOP OFF WITH THE FETA MIXTURE. ADD THE CHERRY TOMATOES AND SLICED LEEKS AND BAKE AT 220 C FOR 8 MIN. SERVE RIGHT AWAY.</description>
		<time>30 min</time>
		<persons>4</persons>
		<ingredients>
			<item>4 slices of ciabatta bread</item>
			<item>150 g feta cheese</item>
			<item>150 g quark</item>
			<item>3 finely chopped garlic cloves</item>
			<item>3 tbsp Niclas Vahé Extra virgin olive oil</item>
			<item>100 g Nicolas Vahé Pesto / black olives og basil</item>
			<item>250 g cherry tomatoes cut in half</item>
			<item>1 finely chopped leek</item>
			<item>Salt and pepper</item>
		</ingredients>
		<nvproducts>
			<item>
				<productnumber>Nv0705</productnumber>
				<productdescription>Pesto med Sorte Oliven og Basilikum</productdescription>
				<imageurl>http://appbilleder.housedoctor.dk/app/Nv0705.jpg</imageurl>
			</item>
			<item>
				<productnumber>Nvlp020</productnumber>
				<productdescription>Ekstra Jomfru Olivenolie</productdescription>
				<imageurl>http://appbilleder.housedoctor.dk/app/Nvlp020.jpg</imageurl>
			</item>
		</nvproducts>
		<recipesurl>http://nicolasvahe.com/--/vegetables/59</recipesurl>
	</recipe>

	<recipe id="62">
		<category>Risretter</category>
		<title>RISOTTO WITH MUSHROOMS</title>
		<smallimageurl>http://www.nicolasvahe.dk/resimgs/320PX/NV.opskrift.3.2.jpg</smallimageurl>
		<bigimageurl>http://www.nicolasvahe.dk/resimgs/960PX/NV.opskrift.3.2.jpg</bigimageurl>
		<description>Bring the water to the boil and add the contents of the bag. Leave to simmer at medium heat with no lid for around 15 minutes until the water has been absorbed. Add olive oil, cream and grated parmesan while stirring. Season with salt and pepper.</description>
		<time>30 min</time>
		<persons>4</persons>
		<ingredients>
			<item>1 bag Nicolas Vahé Risotto / mushroom</item>
			<item>1100 ml water</item>
			<item>2 tbsp olive oil</item>
			<item>100 ml cream</item>
			<item>100 g parmesan</item>
			<item>Salt and pepper </item>
		</ingredients>
		<nvproducts>
			<item>
				<productnumber>Nvfm02</productnumber>
				<productdescription>Risotto med Svampe</productdescription>
				<imageurl>http://appbilleder.housedoctor.dk/app/Nvfm02.jpg</imageurl>
			</item>
		</nvproducts>
		<recipesurl>http://nicolasvahe.com/--/rice/62</recipesurl>
	</recipe>

	<recipe id="63">
		<category>Pasta</category>
		<title>FRESH PASTA WITH RED PEPPER PESTO</title>
		<smallimageurl>http://www.nicolasvahe.dk/resimgs/320PX/NV.opskrift.13.2.jpg</smallimageurl>
		<bigimageurl>http://www.nicolasvahe.dk/resimgs/960PX/NV.opskrift.13.2.jpg</bigimageurl>
		<description>Cook the fresh pasta in a large pan of boiling water until it is al dente. Drain the pasta and place it in a large bowl. Stir in the pesto and season with salt and pepper. Garnish with fresh basil leaves and add parmesan cheese to taste. Serve the pasta with freshly baked bread and/or grilled chicken or fish.</description>
		<time>30 min</time>
		<persons>2</persons>
		<ingredients>
			<item>500 g fresh pasta</item>
			<item>3 tbsp Nicolas Vahé Pesto / pure red pepper</item>
			<item>Salt and pepper</item>
			<item>Fresh basil</item>
			<item>Grated parmesan </item>
		</ingredients>
		<nvproducts>
			<item>
				<productnumber>Nv0704</productnumber>
				<productdescription>Pesto med Rød peber</productdescription>
				<imageurl>http://appbilleder.housedoctor.dk/app/Nv0704.jpg</imageurl>
			</item>
			<item>
				<productnumber>Nv1004</productnumber>
				<productdescription>Fransk Havsalt</productdescription>
				<imageurl>http://appbilleder.housedoctor.dk/app/Nv1004.jpg</imageurl>
			</item>
			<item>
				<productnumber>Nv1005</productnumber>
				<productdescription>Sort Peber</productdescription>
				<imageurl>http://appbilleder.housedoctor.dk/app/Nv1005.jpg</imageurl>
			</item>
		</nvproducts>
		<recipesurl>http://nicolasvahe.com/--/pasta/63</recipesurl>
	</recipe>

	<recipe id="64">
		<category>Salater</category>
		<title>MELON SALAD WITH SESAME SEEDS AND CORIANDER</title>
		<smallimageurl>http://www.nicolasvahe.dk/resimgs/320PX/NV.opskrift.8.2.jpg</smallimageurl>
		<bigimageurl>http://www.nicolasvahe.dk/resimgs/960PX/NV.opskrift.8.2.jpg</bigimageurl>
		<description>Dice the melons, chop the coriander and mix it in a bowl. Add the cane sugar, red wine vinegar, sesame seeds and pepper and toss with your hands. Place in the fridge for 15 min. before serving. Garnish with raspberries.</description>
		<time>30 min</time>
		<persons>4</persons>
		<ingredients>
			<item>1 cantaloupe melon</item>
			<item>1 honeydew melon</item>
			<item>1/2 watermelon</item>
			<item>150 g raspberries</item>
			<item>1 bunch of coriander</item>
			<item>2 tbsp white sesame seeds</item>
			<item>2 tbsp black sesame seeds</item>
			<item>1 tbsp Nicolas Vahé Red wine vinegar / raspberry</item>
			<item>1 tsp cane sugar</item>
			<item>Pepper</item>
		</ingredients>
		<nvproducts>
			<item>
				<productnumber>Nv1005</productnumber>
				<productdescription>Sort Peber</productdescription>
				<imageurl>http://appbilleder.housedoctor.dk/app/Nv1005.jpg</imageurl>
			</item>
			<item>
				<productnumber>Nv1200</productnumber>
				<productdescription>Rødvinseddike med Hindbær</productdescription>
				<imageurl>http://appbilleder.housedoctor.dk/app/Nv1200.jpg</imageurl>
			</item>
		</nvproducts>
		<recipesurl>http://nicolasvahe.com/--/salads/64</recipesurl>
	</recipe>

	<recipe id="67">
		<category>Brød</category>
		<title>FOUGASSE BREAD</title>
		<smallimageurl>http://www.nicolasvahe.dk/resimgs/320PX/NV.opskrift.14.2.jpg</smallimageurl>
		<bigimageurl>http://www.nicolasvahe.dk/resimgs/960PX/NV.opskrift.14.2.jpg</bigimageurl>
		<description>Mix the yeast and salt into the lukewarm water and slowly add the flour.  Either use a mixer or knead the dough by hand for around 5 minutes. Allow the dough to rest in a warm location for around 11/2 hours. Dust some flour over your work surface and roll the dough out to a size of 30x40 cm - leaving it a few centimetres thick. Cover the dough with the  pesto and herbes de Provence. Drizzle with the olive oil and seal the loaf by lifting the left side over to cover the right side. Brush the edges with  a little water and crim Cut 2 cm wide grooves at an angle so that you can see the olive filling.  Bake for 30 minutes at 180 C until the loaf is crisp on top. You can also use artichokes, sun-dried tomatoes or another pesto from  Nicolas Vahé.</description>
		<time>120 min</time>
		<persons>4</persons>
		<ingredients>
			<item>350 ml lukewarm water</item>
			<item>40 g yeast</item>
			<item>650 g plain flour</item>
			<item>1 tsp coarse salt</item>
			<item>150 g Nicolas Vahé Pesto / black olives og basil </item>
			<item>1 tsp herbes de Provence</item>
			<item>6 tbsp Nicolas Vahé Extra virgin olive oil  </item>
		</ingredients>
		<nvproducts>
			<item>
				<productnumber>Nv0705</productnumber>
				<productdescription>Pesto med Sorte Oliven og Basilikum</productdescription>
				<imageurl>http://appbilleder.housedoctor.dk/app/Nv0705.jpg</imageurl>
			</item>
			<item>
				<productnumber>Nvlp020</productnumber>
				<productdescription>Ekstra Jomfru Olivenolie</productdescription>
				<imageurl>http://appbilleder.housedoctor.dk/app/Nvlp020.jpg</imageurl>
			</item>
		</nvproducts>
		<recipesurl>http://nicolasvahe.com/--/bread/67</recipesurl>
	</recipe>

	<recipe id="75">
		<category>Salater</category>
		<title>Winter salad</title>
		<smallimageurl>http://www.nicolasvahe.dk/resimgs/320PX/75.jpg</smallimageurl>
		<bigimageurl>http://www.nicolasvahe.dk/resimgs/960PX/75.jpg</bigimageurl>
		<description>Cut off the branches of the beetroots. Keep the leaves and put them in iced  water to get them nice and crisp so they may later be used as the salad.  Cook the beetroots in the oven at 160 C for 90 minutes. Pinch them with a fork to check if they are cooked. When ready the beetroot should fall off  the fork.  Peel the beetroots; cut them into 2 by 2 cm cubes and place in a bowl. When  they are still warm add 2 tablespoons of raspberry vinaigrette and the pistachio oil. Let the beetroots cool down to room temperature before finishing the salad.  Mix the beetroot leaves with the beetroots and arrange on two plates.  Sprinkle with hazelnuts, pomegranate seeds, raspberries and grapes. Break  the feta cheese over the salad with your hands. Use the last tablespoon of  raspberry vinaigrette to sprinkle around the salad.</description>
		<time>120 min</time>
		<persons>2</persons>
		<ingredients>
			<item>5 fresh beetroots with branches and leaves                                                        A</item>
			<item>A handful of green grapes cut in halves</item>
			<item>Seeds from half a pomegranate</item>
			<item>20 hazelnuts cut in halves </item>
			<item>50 g goat or feta cheese</item>
			<item>A handful of raspberries</item>
			<item>3 tbsp Nicolas Vahé Vinaigrette / raspberry</item>
			<item>1 tbsp Nicolas Vahé Pistachio oil</item>
			<item>Salt and pepper</item>
		</ingredients>
		<nvproducts>
			<item>
				<productnumber>Nv1007</productnumber>
				<productdescription>Salt og Peber - Everyday mix</productdescription>
				<imageurl>http://appbilleder.housedoctor.dk/app/Nv1007.jpg</imageurl>
			</item>
			<item>
				<productnumber>Nv1255</productnumber>
				<productdescription>Vinaigrette med Hindbær</productdescription>
				<imageurl>http://appbilleder.housedoctor.dk/app/Nv1255.jpg</imageurl>
			</item>
			<item>
				<productnumber>Nvlp002</productnumber>
				<productdescription>Olie med Pistacie</productdescription>
				<imageurl>http://appbilleder.housedoctor.dk/app/Nvlp002.jpg</imageurl>
			</item>
		</nvproducts>
		<recipesurl>http://nicolasvahe.com/--/salads/75</recipesurl>
	</recipe>

</data>


text:
using System.Linq;
using Autofac;
using Microsoft.ServiceBus.Messaging;
using Cumulus.Configuration;
using Cumulus.Configuration.Settings;
using Cumulus.DependencyResolution;
using Cumulus.Infrastructure;
using Cumulus.Infrastructure.Dispatching;
using Cumulus.Infrastructure.PropertyInjection;
using Cumulus.Interceptors.Outbound;
using NSubstitute;
using NUnit.Framework;
using Shouldly;

namespace Cumulus.UnitTests.InterceptorTests
{
    [TestFixture]
    public class WhenRegisteringInterceptorsWithAutofac
    {
        private class DummyInterceptor : OutboundInterceptor
        {
        }

        [Test]
        public void TheyShouldBeResolvable()
        {
            var interceptorTypes = new[] {typeof (DummyInterceptor)};

            var builder = new ContainerBuilder();
            var typeProvider = Substitute.For<ITypeProvider>();
            typeProvider.InterceptorTypes.Returns(interceptorTypes);

            builder.RegisterCumulus(typeProvider);

            using (var container = builder.Build())
            using (var dependencyResolver = container.Resolve<IDependencyResolver>())
            using (var scope = dependencyResolver.CreateChildScope())
            {
                var interceptorSetting = new GlobalOutboundInterceptorTypesSetting
                                         {
                                             Value = interceptorTypes
                                         };
                var outboundInterceptorFactory = new OutboundInterceptorFactory(interceptorSetting,
                                                                                new PropertyInjector(Substitute.For<IClock>(),
                                                                                Substitute.For<IDispatchContextManager>(),
                                                                                Substitute.For<ILargeMessageBodyStore>()));

                var dummyBrokeredMessage = new BrokeredMessage();
                var interceptors = outboundInterceptorFactory.CreateInterceptors(scope, dummyBrokeredMessage);

                interceptors.Count().ShouldBe(1);
            }
        }
    }
}


text:
/// <reference path="../../../Northwind/Product/ProductGrid.ts" />

namespace sharp.Serene.BasicSamples {

    @Serenity.Decorators.registerClass()
    export class GroupingAndSummariesInGrid extends Northwind.ProductGrid {

        constructor(container: JQuery) {
            super(container);
        }

        protected createSlickGrid() {
            var grid = super.createSlickGrid();

            // need to register this plugin for grouping or you'll have errors
            grid.registerPlugin(new Slick.Data.GroupItemMetadataProvider());

            this.view.setSummaryOptions({
                aggregators: [
                    new Slick.Aggregators.Avg('UnitPrice'),
                    new Slick.Aggregators.Sum('UnitsInStock'),
                    new Slick.Aggregators.Max('UnitsOnOrder'),
                    new Slick.Aggregators.Avg('ReorderLevel')
                ]
            });

            return grid;
        }

        protected getColumns() {
            var columns = super.getColumns();

            Q.first(columns, x => x.field === 'UnitsOnOrder')
                .groupTotalsFormatter = (totals, col) =>
                    (totals.max ? ('max: ' + Q.coalesce(totals.max[col.field], '')) : '');

            Q.first(columns, x => x.field === 'ReorderLevel')
                .groupTotalsFormatter = (totals, col) =>
                    (totals.avg ? ('avg: ' + Q.coalesce(Q.formatNumber(totals.avg[col.field], '0.'), '')) : '');

            return columns;
        }

        protected getSlickOptions() {
            var opt = super.getSlickOptions();
            opt.showFooterRow = true;
            return opt;
        }

        protected usePager() {
            return false;
        }

        protected getButtons() {
            return [{
                title: 'Group By Category',
                cssClass: 'expand-all-button',
                onClick: () => this.view.setGrouping(
                    [{
                        getter: 'CategoryName'
                    }])
            },
            {
                title: 'Group By Category and Supplier',
                cssClass: 'expand-all-button',
                onClick: () => this.view.setGrouping(
                    [{
                        formatter: x => 'Category: ' + x.value + ' (' + x.count + ' items)',
                        getter: 'CategoryName'
                    }, {
                        formatter: x => 'Supplier: ' + x.value + ' (' + x.count + ' items)',
                        getter: 'SupplierCompanyName'
                    }])
            }, {
                title: 'No Grouping',
                cssClass: 'collapse-all-button',
                onClick: () => this.view.setGrouping([])
            }];
        }
    }
}


text:
Features:
* Cluster support
* Multi (batch) support
* Full stats command support
* Asynchronous IO

Error Handling:
* Timeouts
* Dead-servers & fail-over

Nice-to-have:
* Simple namespacing
* Compression
* Split large keys

Performance:
* Pipe-lining


text:
/**
* @author Mikhail Y. Fursov
*/

#include "Ia32Inst.h"
#include "Ia32GCSafePoints.h"
#include "XTimer.h"
#include "BitSet.h"
#include "Ia32CgUtils.h"

namespace Jitrino
{

#define LIVENESS_FILTER_INST_INTERVAL 128
#define LIVENESS_FILTER_OBJ_INST_INTERVAL 64

static CountTime phase0Timer("ia32::gcpointsinfo::phase0"),
                 phase1Timer("ia32::gcpointsinfo::phase1"),
                 phase1Checker("ia32::gcpointsinfo::phase1Checker"),
                 phase2Timer("ia32::gcpointsinfo::phase2"),
                 phase2Checker("ia32::gcpointsinfo::phase2Checker"),
                 saveResultsTimer("ia32::gcpoints::saveResults");

namespace Ia32 {

static ActionFactory<GCPointsBaseLiveRangeFixer> _gcpoints ("gcpoints");

// does nothing except allows to debugger to not loose local stack if method called is last in code
static void dbg_point() {}

// Helper function, removes element idx from vector in O(1) time
// Moves last element in vector to idx and reduce size by 1
// WARN: elements order could be changed!
static void removeElementAt(GCSafePointPairs& pairs, U_32 idx) {
    assert(!pairs.empty());
    U_32 newSize = (U_32)pairs.size() - 1;
    assert(idx<=newSize);
    if (idx < newSize) {
        pairs[idx] = pairs[newSize];
    }
    pairs.resize(newSize);
}

void GCSafePointsInfo::removePairByMPtrOpnd(GCSafePointPairs& pairs, const Opnd* mptr) const {
#ifdef _DEBUG_
    U_32 nPairs = 0;
#endif
    for (int i = (int)pairs.size(); --i>=0;) {
        MPtrPair& p = pairs[i];
        if (p.mptr == mptr) {
            removeElementAt(pairs, i);
#ifdef _DEBUG_
            nPairs++;
#else
            break; //only one pair in one point for mptr is allowed !
#endif
        }
    }
#ifdef _DEBUG_
    assert(nPairs <= 1);
#endif
}

MPtrPair* GCSafePointsInfo::findPairByMPtrOpnd(GCSafePointPairs& pairs, const Opnd* mptr) {
    for (GCSafePointPairs::iterator it = pairs.begin(), end = pairs.end(); it!=end; ++it) {
        MPtrPair& p = *it;
        if(p.getMptr() == mptr) {
            return &p;
        }
    }
    return NULL;
}

GCSafePointsInfo::GCSafePointsInfo(MemoryManager& _mm, IRManager& _irm, Mode _mode) :
mm(_mm), irm(_irm), pairsByNode(_mm), pairsByGCSafePointInstId(mm),
livenessFilter(mm), ambiguityFilters(mm), staticMptrs(mm), allowMerging(false), opndsAdded(0), instsAdded(0), mode(_mode)
{
    _calculate();
}

bool GCSafePointsInfo::graphHasSafePoints(const IRManager& irm){
    const Nodes& nodes = irm.getFlowGraph()->getNodes();
    for (Nodes::const_iterator it = nodes.begin(), end = nodes.end(); it!=end; ++it) {
        Node* node = *it;
        if (node->isBlockNode()) {
            if (blockHasSafePoints((BasicBlock*)node)) {
                return true;
            }
        }
    }
    return false;
}

bool GCSafePointsInfo::blockHasSafePoints(const Node* b) {
    for (Inst * inst=(Inst*)b->getFirstInst(); inst!=NULL; inst=inst->getNextInst()){
        if (isGCSafePoint(inst)) {
            return true;
        }
    }
    return false;
}

U_32 GCSafePointsInfo::getNumSafePointsInBlock(const Node* b, const GCSafePointPairsMap* pairsMap ) {
    U_32 n = 0;
    for (Inst * inst=(Inst*)b->getFirstInst(); inst!=NULL; inst=inst->getNextInst()){
        if (isGCSafePoint(inst)) {
            if (pairsMap!=NULL) { // if pairs!=NULL counts only gcpoints with non-empty pairs
                GCSafePointPairsMap::const_iterator it = pairsMap->find(inst->getId());
                assert(it!=pairsMap->end());
                GCSafePointPairs* pairs = it->second;
                if (pairs->empty()) {
                    continue;
                }
            }
            n++;
        }
    }
    return n;
}

void GCSafePointsInfo::_calculate() {
    assert(pairsByNode.empty());
    assert(pairsByGCSafePointInstId.empty());

    //check if there are no safepoints in cfg at all
    if (!graphHasSafePoints(irm)) {
        return;
    }
    irm.updateLivenessInfo();
    irm.updateLoopInfo(); //to use _hasLoops property

    insertLivenessFilters();
    allowMerging = true;
    calculateMPtrs();
    if (mode == MODE_2_CALC_OFFSETS) {
        assert(opndsAdded == 0);
        return;
    }
    if ( opndsAdded > 0 ) {
        irm.invalidateLivenessInfo();
        irm.updateLivenessInfo();
    }
    allowMerging  = false;
    filterLiveMPtrsOnGCSafePoints();
}

void GCSafePointsInfo::insertLivenessFilters() {
    AutoTimer tm(phase0Timer);
    const Nodes& nodes = irm.getFlowGraph()->getNodes();
    for (Nodes::const_iterator it = nodes.begin(), end = nodes.end(); it!=end; ++it) {
        Node* node = *it;
        if (node->isBlockNode()) {
            U_32 numInsts = node->getInstCount();
            if (numInsts < LIVENESS_FILTER_INST_INTERVAL) {
                continue;
            }
            U_32 objOps  = 0;
            for (Inst* inst = (Inst*)node->getLastInst(); inst!=NULL; inst = inst->getPrevInst()) {
                if ( (inst->getOpndCount() == 0 && ((inst->getKind() == Inst::Kind_MethodEndPseudoInst)
                        || (inst->getKind() == Inst::Kind_MethodEntryPseudoInst)))
                     || (inst->getMnemonic() == Mnemonic_NOP
                        || inst->getKind() == Inst::Kind_EmptyPseudoInst) )
                {
                    continue;
                }
                Opnd* opnd = inst->getOpnd(0); // VSH: 0 - ????
                if (opnd->getType()->isObject() || opnd->getType()->isManagedPtr()) {
                    objOps++;
                    if (objOps == LIVENESS_FILTER_OBJ_INST_INTERVAL) {
                        break;
                    }
                }
            }
            if (objOps < LIVENESS_FILTER_OBJ_INST_INTERVAL) {
                continue;
            }
             // insert liveness filter for every n-th inst in block
            int nFilters = numInsts / LIVENESS_FILTER_INST_INTERVAL;
            BitSet* ls = new (mm) BitSet(mm, irm.getOpndCount());
            irm.getLiveAtExit(node, *ls);
            int nFiltersLeft = nFilters;
            int instsInInterval = 0;
            for (Inst* inst = (Inst*)node->getLastInst(); nFiltersLeft>0; inst = inst->getPrevInst()) {
                assert(inst!=NULL);
                irm.updateLiveness(inst, *ls);
                instsInInterval++;
                if (instsInInterval == LIVENESS_FILTER_INST_INTERVAL) {
                    nFiltersLeft--;
                    instsInInterval = 0;
                    setLivenessFilter(inst, ls);
                    if (nFiltersLeft != 0) {
                        ls = new (mm) BitSet(*ls);
                    }
                }
            }
        }
    }
}

void GCSafePointsInfo::setLivenessFilter(const Inst* inst, const BitSet* ls) {
    livenessFilter[inst] = ls;
}

const BitSet* GCSafePointsInfo::findLivenessFilter(const Inst* inst) const {
    StlMap<const Inst*, const BitSet*>::const_iterator it = livenessFilter.find(inst);
    if (it == livenessFilter.end()) {
        return NULL;
    }
    return it->second;
}

void GCSafePointsInfo::calculateMPtrs() {
    AutoTimer tm(phase1Timer);
    assert(pairsByNode.empty());
    ControlFlowGraph* fg = irm.getFlowGraph();
    LoopTree* lt =fg->getLoopTree();

    const Nodes& postOrderedNodes = fg->getNodesPostOrder();

    //prepare structures
    pairsByNode.resize(fg->getNodeCount());
    for (Nodes::const_iterator it = postOrderedNodes.begin(), end = postOrderedNodes.end(); it!=end; ++it) {
        Node* node = *it;
        if (node!=fg->getExitNode() && node!=fg->getUnwindNode()) {
            pairsByNode[node->getDfNum()] = new (mm) GCSafePointPairs(mm);
        }
    }

    GCSafePointPairs tmpPairs(mm);
    U_32 nIterations = lt->getMaxLoopDepth() + 1;
    bool changed = true;
    bool restart = false;

#ifdef _DEBUG
    nIterations++; //one more extra iteration to check on debug that nothing changed
#endif
    for (U_32 iteration = 0; iteration < nIterations ; ) {
        changed = false;
        for (Nodes::const_reverse_iterator it = postOrderedNodes.rbegin(), end = postOrderedNodes.rend(); it!=end; ++it) {
            Node* node = *it;
            if (node == fg->getExitNode() || node == fg->getUnwindNode()) {
                continue;
            }
            tmpPairs.clear();
            U_32 instsBefore = instsAdded;
            derivePairsOnEntry(node, tmpPairs);
            if (instsBefore!=instsAdded) {
                restart = true;
                break;
            }
            GCSafePointPairs& nodePairs = *pairsByNode[node->getDfNum()];
            if (node->isBlockNode()) {
                for (Inst * inst=(Inst*)node->getFirstInst(); inst!=NULL; inst=inst->getNextInst()){
                    updatePairsOnInst(inst, tmpPairs);
                    if (isGCSafePoint(inst)) { //saving results on safepoint
                        GCSafePointPairs* instPairs = NULL;
                        instPairs = pairsByGCSafePointInstId[inst->getId()];
                        if (instPairs == NULL) {
                            instPairs = new (mm) GCSafePointPairs(mm);
                            pairsByGCSafePointInstId[inst->getId()] = instPairs;
                        }
                        instPairs->clear();
                        instPairs->insert(instPairs->end(), tmpPairs.begin(), tmpPairs.end());
                    }
                }
                if (iteration == 0 || !hasEqualElements(nodePairs, tmpPairs)) {
                    changed = true;
                    nodePairs.swap(tmpPairs);
                }
            } else {
                nodePairs.swap(tmpPairs);
            }
        }
        if (restart) {  //clear all cached pairs and restart all iterations
            for (Nodes::const_iterator it2 = postOrderedNodes.begin(), end2 = postOrderedNodes.end(); it2!=end2; ++it2) {
                Node* node = *it2;
                GCSafePointPairs* pairs = pairsByNode[node->getDfNum()];
                assert(pairs!=NULL || node->isExitNode() || node == fg->getUnwindNode());
                if (pairs!=NULL) {
                    pairs->clear();
                }
            }
            iteration = 0;
            restart = false;
            continue;
        }
        if (!changed) {
            break;
        }
        iteration++;
    }
#ifdef _DEBUG
    assert(!changed);
    checkPairsOnNodeExits();
#endif
}

static inline int adjustOffsets(I_32 offsetBefore, I_32 dOffset) {
    if (offsetBefore == MPTR_OFFSET_UNKNOWN || dOffset == MPTR_OFFSET_UNKNOWN) {
        return MPTR_OFFSET_UNKNOWN;
    }
    int res = offsetBefore + dOffset;
    assert(res>=0);
    return res;
}

static bool isHeapBase(Opnd* immOpnd) {
    assert(immOpnd->isPlacedIn(OpndKind_Imm));
#ifndef _EM64T_
    return false;
#else
    int64 heapBase = (int64)VMInterface::getHeapBase();
    return immOpnd->getImmValue() == heapBase;
#endif
}

I_32 GCSafePointsInfo::getOffsetFromImmediate(Opnd* offsetOpnd) const {
    if (offsetOpnd->isPlacedIn(OpndKind_Immediate)) {
        if (offsetOpnd->getImmValue() == 0 && offsetOpnd->getRuntimeInfo()!=NULL) {
            irm.resolveRuntimeInfo(offsetOpnd);
        }
        assert(!isHeapBase(offsetOpnd));
        return (I_32)offsetOpnd->getImmValue();
    }
    return MPTR_OFFSET_UNKNOWN;
}

void GCSafePointsInfo::runLivenessFilter(Inst* inst, GCSafePointPairs& pairs) const {
    if (!pairs.empty()) {
        const BitSet* livenessFilter = findLivenessFilter(inst);
        if (livenessFilter!=NULL) {
            for (int i = (int)pairs.size(); --i>=0;) {
                MPtrPair& p = pairs[i];
                if (!livenessFilter->getBit(p.mptr->getId())) {
                    removeElementAt(pairs, i);
                }
            }
        }
    }
}

Opnd* GCSafePointsInfo::getBaseAccordingMode(Opnd* opnd) const {
    //MODE_2_CALC_OFFSETS does not have valid base info, because it does not resolves ambiguity!
    return mode == MODE_1_FIX_BASES ? opnd : NULL;
}

void GCSafePointsInfo::updateMptrInfoInPairs(GCSafePointPairs& res, Opnd* newMptr, Opnd* fromOpnd, int offset, bool fromOpndIsBase) {
   assert(!isStaticFieldMptr(newMptr));
    if (fromOpndIsBase) { //from is base
        removePairByMPtrOpnd(res, newMptr);
        MPtrPair p(newMptr, getBaseAccordingMode(fromOpnd), offset);
        res.push_back(p);
    } else { //fromOpnd is mptr
       MPtrPair* fromPair = findPairByMPtrOpnd(res, fromOpnd);
       assert(fromPair != NULL);
       int newOffset = adjustOffsets(fromPair->offset, offset);
       //remove old pair, add new
       MPtrPair* pair = newMptr == fromOpnd ? fromPair : findPairByMPtrOpnd(res, newMptr);
       if (pair != NULL) { //reuse old pair
           pair->offset = newOffset;
           pair->base = fromPair->base;
           pair->mptr = newMptr;
       } else { // new mptr, was not used before
           MPtrPair toPair(newMptr, fromPair->base, newOffset);
           res.push_back(toPair);
       }
   }
}

static void add_static(Opnd* opnd, StlSet<Opnd*>& set, Opnd* cause) {
    set.insert(opnd);
    if (Log::isEnabled()) {
        Log::out()<<"Registering as static opnd, firstId="<<opnd->getFirstId()<<" reason-opndid:"<<(cause?cause->getFirstId() : (U_32)-1)<<std::endl;
    }
}

void GCSafePointsInfo::filterStaticMptrs(Inst* inst) {
    if (inst->hasKind(Inst::Kind_CallInst)) {
        CallInst* callInst = (CallInst*)inst;
        Opnd::RuntimeInfo * rt = callInst->getRuntimeInfo();
        if (rt && rt->getKind() == Opnd::RuntimeInfo::Kind_HelperAddress
            && ((VM_RT_SUPPORT)(POINTER_SIZE_INT)rt->getValue(0) == VM_RT_GET_STATIC_FIELD_ADDR_WITHRESOLVE))
        {
            Opnd* callRes = callInst->getOpnd(0);
            add_static(callRes, staticMptrs, NULL);
        }
    } else if (inst->getMnemonic() == Mnemonic_MOV) {
        Opnd* toOpnd = inst->getOpnd(0);
        Opnd* fromOpnd = inst->getOpnd(1);
        if (!isManaged(fromOpnd) && !isManaged(toOpnd)) {
            return;
         }
        if (fromOpnd->isPlacedIn(OpndKind_Mem) && fromOpnd->getMemOpndKind() == MemOpndKind_Heap) {
            //loading value from memory -> can be object only, not is a mptr to a static field
            return;
        }
        if (staticMptrs.find(fromOpnd)!=staticMptrs.end()) {
            add_static(toOpnd, staticMptrs, fromOpnd);
        } else if (fromOpnd->isPlacedIn(OpndKind_Imm)) { //imms are compile-time known values -> can only be static
            Opnd::RuntimeInfo* info = fromOpnd->getRuntimeInfo();
            bool isStaticFieldMptr = info!=NULL && info->getKind() == Opnd::RuntimeInfo::Kind_StaticFieldAddress;
            if (isStaticFieldMptr) {
                add_static(fromOpnd, staticMptrs, NULL);
                add_static(toOpnd, staticMptrs, fromOpnd);
            }
        }
   }
}

void GCSafePointsInfo::updatePairsOnInst(Inst* inst, GCSafePointPairs& res) {
    runLivenessFilter(inst, res);//filter pairs with dead mptrs from list

    Inst::Opnds opnds(inst, Inst::OpndRole_Explicit | Inst::OpndRole_Auxilary |Inst::OpndRole_UseDef);
    U_32 defIndex = opnds.begin();
    U_32 useIndex1 = opnds.next(defIndex);

    if (defIndex >= opnds.end() || useIndex1 >= opnds.end()
        || (inst->getOpndRoles(defIndex) & Inst::OpndRole_Def) == 0
        || (inst->getOpndRoles(useIndex1) & Inst::OpndRole_Use) == 0 )
    {
        return;
    }
    Opnd* opnd = inst->getOpnd(defIndex);
    Type* opndType = opnd->getType();
    if (!opndType->isObject() && !opndType->isManagedPtr()) {
        return;
    }
   filterStaticMptrs(inst);
   if (isStaticFieldMptr(opnd)) {
        removePairByMPtrOpnd(res, opnd);
       return; // no more analysis required
   }
   if (mode == MODE_1_FIX_BASES) { //3 addr form
        if (opndType->isObject()) { // MODE_1_FIX_BASES -> obj & mptr types are not coalesced
            StlMap<Inst*, Opnd*>::const_iterator ait;
            if (!ambiguityFilters.empty() && ((ait = ambiguityFilters.find(inst))!=ambiguityFilters.end())) {
                //mptr ambiguity filter -> replace old base with new(opnd) in pairs
                const Opnd* mptr = ait->second;
                MPtrPair* pair =  findPairByMPtrOpnd(res, mptr);
#ifdef _DEBUG
                Opnd* oldBase = inst->getOpnd(useIndex1); //inst is: newBase = oldBase
                assert(pair!=NULL);
                assert(pair->getBase() == oldBase || pair->getBase() == opnd); // ==opnd-> already resolved in dominant block
#endif

                pair->base = opnd;
            }
        } else { //def of mptr
            // detect which operand is base
            Opnd* fromOpnd = inst->getOpnd(useIndex1);
            U_32 useIndex2 = opnds.next(useIndex1);
            Opnd* fromOpnd2 = useIndex2!=opnds.end() ? inst->getOpnd(useIndex2) : NULL;
            if (!(fromOpnd->getType()->isObject() || fromOpnd->getType()->isManagedPtr())) {
                assert(fromOpnd2!=NULL);
                Opnd* tmp = fromOpnd; fromOpnd = fromOpnd2; fromOpnd2 = tmp;
            }
            assert(fromOpnd->getType()->isObject() || fromOpnd->getType()->isManagedPtr());
            I_32 offset = MPTR_OFFSET_UNKNOWN;
            if (inst->getMnemonic() == Mnemonic_LEA) {
                assert(fromOpnd->isPlacedIn(OpndKind_Memory));
                Opnd* scaleOpnd = fromOpnd->getMemOpndSubOpnd(MemOpndSubOpndKind_Scale);
                if (scaleOpnd == NULL) {
                    Opnd* displOpnd = fromOpnd->getMemOpndSubOpnd(MemOpndSubOpndKind_Displacement);
                    assert(displOpnd!=NULL);
                    offset = (I_32)displOpnd->getImmValue();
                }
                fromOpnd = fromOpnd->getMemOpndSubOpnd(MemOpndSubOpndKind_Base);
            } else if (fromOpnd2!=NULL) {
                Opnd* offsetOpnd = fromOpnd2;
                offset = getOffsetFromImmediate(offsetOpnd);
            }
            updateMptrInfoInPairs(res, opnd, fromOpnd, offset, fromOpnd->getType()->isObject());
            dbg_point();
        }
    } else { // mode == MODE_2_CALC_OFFSETS   - 2 addr form
        //we can't rely on base/mptr type info here.
        //algorithm:
        if (inst->hasKind(Inst::Kind_ControlTransferInst) ||
            inst->getMnemonic() == Mnemonic_MOVS8         ||
            inst->getMnemonic() == Mnemonic_MOVS16        ||
            inst->getMnemonic() == Mnemonic_MOVS32        ||
            inst->getMnemonic() == Mnemonic_MOVS64        ||
            inst->getMnemonic() == Mnemonic_CMPSB         ||
            inst->getMnemonic() == Mnemonic_CMPSW         ||
            inst->getMnemonic() == Mnemonic_CMPSD         ) {
            //Do nothing, calls return only bases
        } else {
            Opnd* fromOpnd = NULL;
            I_32 offset = 0;
            Mnemonic mn = inst->getMnemonic();

            Mnemonic conditionalMnem = getBaseConditionMnemonic(mn);
            if (conditionalMnem != Mnemonic_NULL)
                mn = conditionalMnem;

            switch (mn) {
                case Mnemonic_XOR:
                case Mnemonic_MOV:
                case Mnemonic_CMOVcc:
                    assert(mn != Mnemonic_XOR || inst->getOpnd(useIndex1)==opnd);
                    fromOpnd = inst->getOpnd(useIndex1);
                    break;
                case Mnemonic_ADD: {
                case Mnemonic_SUB:
                        fromOpnd = opnd;
                        Opnd* offsetOpnd = inst->getOpnd(useIndex1);
                        Opnd* immOffset = OpndUtils::findImmediateSource(offsetOpnd);
                        if (immOffset) {
                           if (isHeapBase(immOffset)) {
                               offset = 0;
                           } else {
                               offset = getOffsetFromImmediate(immOffset);
                           }
                        } else {
                           offset = MPTR_OFFSET_UNKNOWN;
                        }
                    }
                    break;
                case Mnemonic_LEA: {
                        fromOpnd = inst->getOpnd(useIndex1);
                        assert(fromOpnd->isPlacedIn(OpndKind_Memory));
                        Opnd* scaleOpnd = fromOpnd->getMemOpndSubOpnd(MemOpndSubOpndKind_Scale);
                        if (scaleOpnd == NULL) {
                            Opnd* displOpnd = fromOpnd->getMemOpndSubOpnd(MemOpndSubOpndKind_Displacement);
                            assert(displOpnd!=NULL);
                            offset = (I_32)displOpnd->getImmValue();
                        } else {
                            offset = MPTR_OFFSET_UNKNOWN;
                        }
                        fromOpnd = fromOpnd->getMemOpndSubOpnd(MemOpndSubOpndKind_Base);
                    }
                    break;
                default: assert(0);
            }
            bool fromIsMptrOrObj = fromOpnd->getType()->isObject() || fromOpnd->getType()->isManagedPtr();
            MPtrPair* fromPair = fromIsMptrOrObj ? findPairByMPtrOpnd(res, fromOpnd) : NULL;

            if (fromPair != NULL || offset!=0)  {//opnd is mptr -> update pairs
                updateMptrInfoInPairs(res, opnd, fromOpnd, offset,  fromPair == NULL);
            } else {
                //new def of base -> we must remove all pairs where opnd acts as base or mptr
                //the problem is that in MODE2 we do not save info about bases (no ambiguity resolution is done)
                //so we can't match pairs where opnd is a base.
                //Solution: let pairs derived from this base to live, due to the fact that
                //such pairs must have static offset and base redefinition will not corrupt info.
                //For pairs with unknown offset there is a live base -> MODE1 cares about it
                removePairByMPtrOpnd(res, opnd);
            }
        }
    } // else mode2
}

void GCSafePointsInfo::derivePairsOnEntry(const Node* node, GCSafePointPairs& res) {
    assert(res.empty());
    // optimization: filter out those mptrs that are not live at entry.
    // this situation is possible because of updatePairsOnInst() function does not track liveness
    // and allows dead operands in pairs for block end;
    const BitSet* ls = irm.getLiveAtEntry(node);
    const Edges& edges=node->getInEdges();

    assert(irm.getFlowGraph()->hasValidOrdering());

    //step1: add all live pairs from pred edges into res
    for (Edges::const_iterator ite = edges.begin(), ende = edges.end(); ite!=ende; ++ite) {
        Edge* edge = *ite;
        Node * predNode =edge->getSourceNode();
        const GCSafePointPairs& predPairs = *pairsByNode[predNode->getDfNum()];
        res.reserve(res.size() + predPairs.size());
        for (GCSafePointPairs::const_iterator it = predPairs.begin(), end = predPairs.end(); it!=end; ++it) {
            const MPtrPair& predPair = *it;
            if (ls->getBit(predPair.mptr->getId())) {
                res.push_back(predPair);//by value
            }
        }
    }

    //step 2: merge pairs with the same (mptr, base) and process ambiguos pairs
    bool needToFilterDeadPairs = false;
    U_32 instsAddedBefore = instsAdded;
    std::sort(res.begin(), res.end());
    for (U_32 i=0, n = (U_32)res.size(); i < n; i++) {
        MPtrPair& p1 = res[i];
        Opnd* newBase = NULL; //new base opnd to merge ambiguos mptrs
        while (i+1 < n) {
            const MPtrPair& p2 = res[i+1];
            if (p1.mptr == p2.mptr) {
                if (p1.base == p2.base) { //same base & mptr -> merge offset
                    if (p1.offset != p2.offset) {
                        p1.offset = MPTR_OFFSET_UNKNOWN;
                    }
                } else { //equal mptrs with a different bases -> add var=baseX to prevBlocks and replace pairs with new single pair
                    assert(mode == MODE_1_FIX_BASES);
                    assert(allowMerging);
                    if (newBase == NULL) { //first pass for this ambiguous mptrs fix them all
                        newBase = irm.newOpnd(p1.base->getType());
                        opndsAdded++;
                        U_32 dInsts = 0;
                        for (Edges::const_iterator ite = edges.begin(), ende = edges.end(); ite!=ende; ++ite) {
                            Edge* edge = *ite;
                            Node * predNode =edge->getSourceNode();
                            GCSafePointPairs& predPairs = *pairsByNode[predNode->getDfNum()];
                            for (GCSafePointPairs::iterator it = predPairs.begin(), end = predPairs.end(); it!=end; ++it) {
                                MPtrPair& predPair = *it;
                                if (predPair.mptr == p1.mptr) { //ok remove this pair, add vardef, add new pair
                                    Opnd* oldBase = predPair.base;
                                    assert(predNode->isBlockNode());
                                    BasicBlock* predBlock = (BasicBlock*)predNode;
                                    //add var def inst to predBlock
                                    Inst* baseDefInst = irm.newCopyPseudoInst(Mnemonic_MOV, newBase, oldBase);
                                    Inst* lastInst = (Inst*)predBlock->getLastInst();
                                    if (lastInst!=NULL && lastInst->hasKind(Inst::Kind_ControlTransferInst)) {
                                        baseDefInst->insertBefore(lastInst);
                                    } else {
                                        predBlock->appendInst(baseDefInst);
                                    }
                                    if (predPair.offset!=p1.offset) {
                                        p1.offset = MPTR_OFFSET_UNKNOWN;
                                    }
                                    dInsts++;
                                    ambiguityFilters[baseDefInst] = p1.mptr;
                                    //and now we should remove oldBase from next nodes in topological ordering
                                    //oldBase could be cached and merging process could be started for oldBase and newBase in inner loops heads
                                    //we will do it one time after the all predPairs is processed for the current node
                                    break;//go to next node processing
                                }
                            }
                        }
                        p1.base = newBase;
                        assert(dInsts > 1);
                        instsAdded+=dInsts;
                    }
                }
                needToFilterDeadPairs = true;
                i++;
            } else {
                break;
            }
        } //while
    }

    //step3:
    if (instsAdded==instsAddedBefore && needToFilterDeadPairs) { //if nstsAdded!=instsAddedBefore -> recalculation restarts
        //step 3: leave only p1(see step2) pairs
        //unique -> remove all pairs with equal mptr but the first
        GCSafePointPairs::iterator newEnd = std::unique(res.begin(), res.end(), &MPtrPair::equalMptrs);
        res.resize(newEnd - res.begin());
    }

}

void GCSafePointsInfo::filterLiveMPtrsOnGCSafePoints() {
    AutoTimer tm(phase2Timer);
    assert(!pairsByNode.empty());
    //unoptimized impl -> analyzing all blocks -> could be moved to GCMap
    const Nodes& nodes = irm.getFlowGraph()->getNodes();
    BitSet ls(mm, irm.getOpndCount());
    for (Nodes::const_iterator it = nodes.begin(), end = nodes.end(); it!=end; ++it) {
        Node* node = *it;
        if (!node->isBlockNode()) {
            continue;
        }
        U_32 nSafePoints = getNumSafePointsInBlock((BasicBlock*)node, &pairsByGCSafePointInstId);
        if (nSafePoints == 0) {
            continue;
        }
        // ok this basic block has safepoints
        U_32 nSafePointsTmp = nSafePoints;
        // remove pairs with dead mptr, use liveness to do it;
        ls.clear();
        irm.getLiveAtExit(node, ls);
        nSafePointsTmp = nSafePoints;
        for (Inst * inst=(Inst*)node->getLastInst();;inst=inst->getPrevInst()) {
            assert(inst!=NULL);
            if (isGCSafePoint(inst)) {
                GCSafePointPairs& pairs  = *pairsByGCSafePointInstId[inst->getId()];
                if (!pairs.empty()) {
                    nSafePointsTmp--;
                    for (int i = (int)pairs.size(); --i>=0;) {
                        MPtrPair& p = pairs[i];
                        if (!ls.getBit(p.mptr->getId())) {
                            removeElementAt(pairs, i);
                        }
                    }
                }
                if (nSafePointsTmp == 0) {
                    break;
                }
            }
            irm.updateLiveness(inst, ls);
        }
    }
#ifdef _DEBUG
    checkPairsOnGCSafePoints();
#endif
}

/// checks that sets of mptrs that come to any node from any edge are equal
void GCSafePointsInfo::checkPairsOnNodeExits() const {
    AutoTimer tm(phase1Checker);
    assert(!pairsByNode.empty());
    ControlFlowGraph* fg = irm.getFlowGraph();
    const Nodes& nodes = fg->getNodes();
    for (Nodes::const_iterator it = nodes.begin(), end = nodes.end(); it!=end; ++it ) {
        Node* node = *it;
        if (node == fg->getUnwindNode() || node==fg->getExitNode()) {
            continue;
        }
        const BitSet* ls = irm.getLiveAtEntry(node);
        if(node->hasTwoOrMorePredEdges()) {
            const Edges& edges=node->getInEdges();
            Edge* edge1 = edges.front();
            Node * predNode1 =edge1->getSourceNode();
            const GCSafePointPairs& pairs1 = *pairsByNode[predNode1->getDfNum()];
            //ensure that first edge mptr set is equal to edge2..N set
            for (Edges::const_iterator ite = edges.begin() + 1, ende = edges.end(); ite!=ende; ++ite) {
                Edge* edge2 = *ite;
                Node * predNode2 =edge2->getSourceNode();
                const GCSafePointPairs& pairs2 = *pairsByNode[predNode2->getDfNum()];
                //now check that for every mptr in pairs1 there is a pair in pairs2 with the same mptr
                for (U_32 i1 = 0, n1 = (U_32)pairs1.size();i1<n1; i1++) {
                    const MPtrPair& p1 = pairs1[i1];
                    if (ls->getBit(p1.mptr->getId())) {
                        for (U_32 i2 = 0; ; i2++) {
                            assert(i2 < pairs2.size());
                            const MPtrPair& p2 = pairs2[i2];
                            if (p1.mptr == p2.mptr) {
                                break;
                            }
                        }
                    }
                }
                // and vice versa
                for (U_32 i2 = 0, n2 = (U_32)pairs2.size();i2<n2; i2++) {
                    const MPtrPair& p2 = pairs2[i2];
                    if (ls->getBit(p2.mptr->getId())) {
                        for (U_32 i1 = 0; ; i1++) {
                            assert(i1 < pairs1.size());
                            const MPtrPair& p1 = pairs1[i1];
                            if (p1.mptr == p2.mptr) {
                                break;
                            }
                        }
                    }
                }
            } //for edge2...edge[N]
        }
    }
}

// checks that we've collected pairs for every live mptr on safe point
void GCSafePointsInfo::checkPairsOnGCSafePoints() const {
    if (mode == MODE_2_CALC_OFFSETS) { // check is done using type info. Type info is not available for mode2
        return;
    }
    AutoTimer tm(phase2Checker);
    const Nodes& nodes = irm.getFlowGraph()->getNodes();
    U_32 nOpnds = irm.getOpndCount();
    BitSet ls(mm, nOpnds);
    for (Nodes::const_iterator it = nodes.begin(), end = nodes.end(); it!=end; ++it) {
        Node* node = *it;
        if (!node->isBlockNode()) {
            continue;
        }
        U_32 nSafePoints = getNumSafePointsInBlock((BasicBlock*)node);
        if (nSafePoints== 0) {
            continue;
        }
        U_32 nSafePointsTmp = nSafePoints;
        irm.getLiveAtExit(node, ls);
        for (Inst * inst=(Inst*)node->getLastInst(); nSafePointsTmp > 0; inst=inst->getPrevInst()) {
            assert(inst!=NULL);
            if (isGCSafePoint(inst)) {
                nSafePointsTmp--;
                GCSafePointPairsMap::const_iterator mit = pairsByGCSafePointInstId.find(inst->getId());
                assert(mit!=pairsByGCSafePointInstId.end());
                const GCSafePointPairs& pairs = *mit->second;
                BitSet::IterB liveOpnds(ls);
                for (int i = liveOpnds.getNext(); i != -1; i = liveOpnds.getNext()) {
                    Opnd* opnd = irm.getOpnd(i);
                    if (opnd->getType()->isManagedPtr()) {
                        if (staticMptrs.find(opnd)!= staticMptrs.end()) {
                            continue;
                        }
                        for (U_32 j=0; ; j++) {
                            assert(j<pairs.size());
                            const MPtrPair&  pair = pairs[j];
                            if (pair.mptr == opnd) {
                                break;
                            }
                        }
                    }
                } //for opnds
            }
            irm.updateLiveness(inst, ls);
        }
    }
}

static U_32 select_1st(const std::pair<U_32, GCSafePointPairs*>& p) {return p.first;}

void GCSafePointsInfo::dump(const char* stage) const {
    Log::out()<<"========================================================================"<<std::endl;
    Log::out()<<"__IR_DUMP_BEGIN__: pairs dump"<<std::endl;
    Log::out()<<"========================================================================"<<std::endl;
    //sort by inst id
    const GCSafePointPairsMap& map = pairsByGCSafePointInstId;
    StlVector<U_32> insts(mm, map.size());
    std::transform(map.begin(), map.end(), insts.begin(), select_1st);
    std::sort(insts.begin(), insts.end());

    //for every inst sort by mptr id and dump
    for (size_t i = 0; i<insts.size(); i++) {
        U_32 id = insts[i];
        const GCSafePointPairs* pairs = map.find(id)->second;
        Log::out()<<"inst="<<id<<" num_pairs="<<pairs->size()<<std::endl;
        GCSafePointPairs cloned = *pairs;
        std::sort(cloned.begin(), cloned.end());
        for(size_t j=0; j<cloned.size(); j++) {
            MPtrPair& p = cloned[j];
            Log::out()<<"    mptr="<< p.mptr->getFirstId()
                <<" base="<<(p.base!=NULL?(int)p.base->getFirstId():-1)
                <<" offset="<<p.offset<<std::endl;
        }
    }
    Log::out()<<"========================================================================"<<std::endl;
    Log::out()<<"__IR_DUMP_END__: pairs dump"<<std::endl;
    Log::out()<<"========================================================================"<<std::endl;

}

#define MAX(a,b) (((a) > (b)) ? (a) : (b))

void GCPointsBaseLiveRangeFixer::runImpl() {
    bool disableStaticOffsets = false;
    getArg("disable_static_offsets", disableStaticOffsets);
    MemoryManager mm("GCSafePointsMarker");
    GCSafePointsInfo info(mm, *irManager, GCSafePointsInfo::MODE_1_FIX_BASES);

    if (Log::isEnabled()) {
        info.dump(getTagName());
    }

    if(!info.hasPairs()) {
        return;
    }
    AutoTimer tm(saveResultsTimer);
    const Nodes& nodes = irManager->getFlowGraph()->getNodes();
    StlVector<Opnd*> basesAndMptrs(mm);
    StlVector<I_32> offsets(mm);
    for (Nodes::const_iterator it = nodes.begin(), end = nodes.end(); it!=end; ++it) {
        Node *node = *it;
        if (!node->isBlockNode()) {
            continue;
        }
        for (Inst * inst=(Inst*)node->getFirstInst(); inst!=NULL; inst=inst->getNextInst()) {
            if (IRManager::isGCSafePoint(inst)) {
                const GCSafePointPairs& pairs = info.getGCSafePointPairs(inst);
                if (pairs.empty()) {
                    continue;
                }
                sideEffect = SideEffect_InvalidatesLivenessInfo;
                basesAndMptrs.clear();
                offsets.clear();
                if (!disableStaticOffsets) {
                    //bases to adjust liveness info. No bases from pairs with valid static offsets get into this set
                    for (GCSafePointPairs::const_iterator it = pairs.begin(), end = pairs.end(); it!=end; ++it) {
                        const MPtrPair& p = *it;
                        if (p.getOffset() == MPTR_OFFSET_UNKNOWN) { // adjust base live range
                            Opnd* base = p.getBase();
                            if (std::find(basesAndMptrs.begin(), basesAndMptrs.end(), base) == basesAndMptrs.end()) {
                                basesAndMptrs.push_back(p.getBase());
                                offsets.push_back(0);
                            }
                        }

                    }
                } else { //ignore static offsets info, adjust live range for all bases
                    std::transform(pairs.begin(), pairs.end(), basesAndMptrs.begin(), std::mem_fun_ref(&MPtrPair::getBase));
                    std::sort(basesAndMptrs.begin(), basesAndMptrs.end());
                    StlVector<Opnd*>::iterator newEnd = std::unique(basesAndMptrs.begin(), basesAndMptrs.end());
                    basesAndMptrs.resize(newEnd - basesAndMptrs.begin());
                    std::fill(offsets.begin(), offsets.end(), 0);
                }
                if (!basesAndMptrs.empty()) {
                    GCInfoPseudoInst* gcInst = irManager->newGCInfoPseudoInst(basesAndMptrs);
                    gcInst->desc = getTagName();
                    gcInst->offsets.resize(offsets.size());
                    std::copy(offsets.begin(), offsets.end(), gcInst->offsets.begin());
                    gcInst->insertAfter(inst);
                }
            } //if inst is gc safe point
        } //for insts
    }
}

}} //namespace


text:
package com.genius.marvel.antman.zookeeper;

/**
 * @author Chuck Liu
 * @date 9/24/17
 * @time 4:26 PM
 */
public class ZookeeperOperation {

    public String get(String key) {
        return "";
    }

    public void watch(String key) {

    }
}


text:
<?xml version="1.0" encoding="utf-8"?>
<TextView xmlns:android="http://schemas.android.com/apk/res/android"
    android:layout_width="match_parent"
    android:layout_height="?attr/actionBarSize"
    android:background="@color/t2_6_background"
    android:gravity="center"
    android:orientation="vertical"
    android:textColor="@color/text_color" />


text:
var path = require('path'),
    fs = require('fs'),
    config = require('../../config');

var tDir = config._fileDir;

var filelist = fs.readdirSync(tDir);
var globallist = fs.readdirSync(path.join(tDir,'Global'));

var filemap = {},
    files = [];

filelist.forEach(function(file) {
  if(file == 'LICENSE') return ;
  var name = path.basename(file,config._ext).toLowerCase();
  filemap[name] = file;
  files.push(name);
});

globallist.forEach(function(file) {
  if(file == 'LICENSE') return ;
  var name = path.basename(file,config._ext).toLowerCase();
  filemap[name] = path.join('Global',file);
  files.push(name);
});

exports.filemap = filemap;
exports.filelist = files;


text:
import { OpacityType } from './opacity.type';

export interface DatumParams {
  start: OpacityType;
  end: OpacityType;
  duration: string;
}

export interface Datum {
  value: 'data';
  params: DatumParams;
}


text:
import multiprocessing
bind = '127.0.0.1:8001'
workers = multiprocessing.cpu_count() * 2 + 1
# errorlog = '/var/log/nginx/gunicorn-error.log'
# accesslog = '/var/log/nginx/gunicorn-access.log'