Register form mapping information.
340254
public function registerFormMapping()
    {
        FormHelper::registerFormTypeMapping([
            'sonata_type_admin' => AdminType::class,
            'sonata_type_model' => ModelType::class,
            'sonata_type_model_list' => ModelListType::class,
            'sonata_type_model_reference' => ModelReferenceType::class,
            'sonata_type_model_hidden' => ModelHiddenType::class,
            'sonata_type_model_autocomplete' => ModelAutocompleteType::class,
            'sonata_type_native_collection' => CollectionType::class,
            'sonata_type_choice_field_mask' => ChoiceFieldMaskType::class,
            'sonata_type_filter_number' => NumberType::class,
            'sonata_type_filter_choice' => ChoiceType::class,
            'sonata_type_filter_default' => DefaultType::class,
            'sonata_type_filter_date' => DateType::class,
            'sonata_type_filter_date_range' => DateRangeType::class,
            'sonata_type_filter_datetime' => DateTimeType::class,
            'sonata_type_filter_datetime_range' => DateTimeRangeType::class,
            'tab' => TabType::class,
        ]);

        FormHelper::registerFormExtensionMapping('form', [
            'sonata.admin.form.extension.field',
            'mopa_bootstrap.form.type_extension.help',
            'mopa_bootstrap.form.type_extension.legend',
            'mopa_bootstrap.form.type_extension.error',
            'mopa_bootstrap.form.type_extension.widget',
            'mopa_bootstrap.form.type_extension.horizontal',
            'mopa_bootstrap.form.type_extension.widget_collection',
            'mopa_bootstrap.form.type_extension.tabbed',
        ]);

        FormHelper::registerFormExtensionMapping('choice', [
            'sonata.admin.form.extension.choice',
        ]);

        FormHelper::registerFormExtensionMapping('button', [
            'mopa_bootstrap.form.type_extension.button',
        ]);

        FormHelper::registerFormExtensionMapping('date', [
            'mopa_bootstrap.form.type_extension.date',
        ]);
    }
59164
public function register()
    {
        $this->commands('Kris\LaravelFormBuilder\Console\FormMakeCommand');

        $this->registerHtmlIfNeeded();
        $this->registerFormIfHeeded();

        $this->mergeConfigFrom(
            __DIR__ . '/../../config/config.php',
            'laravel-form-builder'
        );

        $this->registerFormHelper();

        $this->app->singleton('laravel-form-builder', function ($app) {

            return new FormBuilder($app, $app['laravel-form-helper'], $app['events']);
        });

        $this->app->alias('laravel-form-builder', 'Kris\LaravelFormBuilder\FormBuilder');

        $this->app->afterResolving(Form::class, function ($object, $app) {
            $request = $app->make('request');

            if (in_array(ValidatesWhenResolved::class, class_uses($object)) && $request->method() !== 'GET') {
                $form = $app->make('laravel-form-builder')->setDependenciesAndOptions($object);
                $form->buildForm();
                $form->redirectIfNotValid();
            }
        });
    }
707090
public function registerStandardObjects()
	{
		$this->extensionMap = new ExtensionMap();
		$this->extensions = $this->extensionMap->getRegisteredExtensionNames();
		$this->finder->files();
	}
832210
public static function registerColumnDisplayer()
    {
        $map = [
            'editable'    => Displayers\Editable::class,
            'switch'      => Displayers\SwitchDisplay::class,
            'switchGroup' => Displayers\SwitchGroup::class,
            'select'      => Displayers\Select::class,
            'image'       => Displayers\Image::class,
            'label'       => Displayers\Label::class,
            'button'      => Displayers\Button::class,
            'link'        => Displayers\Link::class,
            'badge'       => Displayers\Badge::class,
            'progressBar' => Displayers\ProgressBar::class,
            'radio'       => Displayers\Radio::class,
            'checkbox'    => Displayers\Checkbox::class,
            'orderable'   => Displayers\Orderable::class,
            'table'       => Displayers\Table::class,
            'expand'      => Displayers\Expand::class,
            'modal'       => Displayers\Modal::class,
        ];

        foreach ($map as $abstract => $class) {
            Column::extend($abstract, $class);
        }
    }
814695
async def register(self, request):
        """"""
        session = await get_session(request)
        user_id = session.get('user_id')
        if user_id:
            return redirect(request, 'timeline')

        error = None
        form = None
        if request.method == 'POST':
            form = await request.post()

            user_id = await db.get_user_id(self.mongo.user, form['username'])
            if not form['username']:
                error = 'You have to enter a username'
            elif not form['email'] or '@' not in form['email']:
                error = 'You have to enter a valid email address'
            elif not form['password']:
                error = 'You have to enter a password'
            elif form['password'] != form['password2']:
                error = 'The two passwords do not match'
            elif user_id is not None:
                error = 'The username is already taken'
            else:
                await self.mongo.user.insert(
                    {'username': form['username'],
                     'email': form['email'],
                     'pw_hash': generate_password_hash(form['password'])})
                return redirect(request, 'login')
        return {"error": error, "form": form}
1225474
def _register_self(self, logfile, key=JobDetails.topkey, status=JobStatus.unknown):
        """"""
        fullkey = JobDetails.make_fullkey(self.full_linkname, key)
        if fullkey in self.jobs:
            job_details = self.jobs[fullkey]
            job_details.status = status
        else:
            job_details = self._register_job(key, self.args, logfile, status)
1155984
public function showRegistrationForm()
    {
        //if registration is closed, deny access
        if (!config('back-project.registration_open')) {
            abort(403, trans('back-project::base.registration_closed'));
        }
        $this->data['title'] = trans('back-project::base.register'); // set the page title
        return view('back-project::auth.register', $this->data);
    }
469253
protected function registerBladeExtensions() : void {
		$blade = $this->app['view']->getEngineResolver()->resolve('blade')->getCompiler();

		$blade->directive('javascripts', function($value){
			return "<?php echo basset_javascripts($value); ?>";
		});

		$blade->directive('stylesheets', function($value){
			return "<?php echo basset_stylesheets($value); ?>";
		});

		$blade->directive('assets', function($value){
			return "<?php echo basset_assets($value); ?>";
		});
	}
117563
def register(request,
             email_template='locksmith/registration_email.txt',
             registration_template=getattr(settings, 'LOCKSMITH_REGISTER_TEMPLATE', 'locksmith/register.html'),
             registered_template=getattr(settings, 'LOCKSMITH_REGISTERED_TEMPLATE', 'locksmith/registered.html'),
            ):
    '''
        
    '''
    if request.method == 'POST':
        form = KeyForm(request.POST)
        if form.is_valid():
            newkey = form.save(commit=False)
            newkey.key = uuid.uuid4().hex
            newkey.status = 'U'
            newkey.save()

            send_key_email(newkey, email_template)
            return render_to_response(registered_template, {'key': newkey, 'LOCKSMITH_BASE_TEMPLATE': settings.LOCKSMITH_BASE_TEMPLATE }, context_instance=RequestContext(request))
    else:
        form = KeyForm()
    return render_to_response(registration_template, {'form':form, 'LOCKSMITH_BASE_TEMPLATE': settings.LOCKSMITH_BASE_TEMPLATE}, context_instance=RequestContext(request))
837397
public void registerMap(Class src) {
        List<BeanMappingObject> objects = BeanMappingParser.parseMapMapping(src);
        for (BeanMappingObject object : objects) {
            register(object);
        }
    }
573773
public static function registerBuiltinFields()
    {
        $map = [
            'button'         => Field\Button::class,
            'checkbox'       => Field\Checkbox::class,
            'color'          => Field\Color::class,
            'currency'       => Field\Currency::class,
            'date'           => Field\Date::class,
            'dateRange'      => Field\DateRange::class,
            'datetime'       => Field\Datetime::class,
            'dateTimeRange'  => Field\DatetimeRange::class,
            'datetimeRange'  => Field\DatetimeRange::class,
            'decimal'        => Field\Decimal::class,
            'display'        => Field\Display::class,
            'divider'        => Field\Divide::class,
            'divide'         => Field\Divide::class,
            'embeds'         => Field\Embeds::class,
            'editor'         => Field\Editor::class,
            'email'          => Field\Email::class,
            'file'           => Field\File::class,
            'hasMany'        => Field\HasMany::class,
            'hidden'         => Field\Hidden::class,
            'id'             => Field\Id::class,
            'image'          => Field\Image::class,
            'ip'             => Field\Ip::class,
            'map'            => Field\Map::class,
            'mobile'         => Field\Mobile::class,
            'month'          => Field\Month::class,
            'multipleSelect' => Field\MultipleSelect::class,
            'number'         => Field\Number::class,
            'password'       => Field\Password::class,
            'radio'          => Field\Radio::class,
            'rate'           => Field\Rate::class,
            'select'         => Field\Select::class,
            'slider'         => Field\Slider::class,
            'switch'         => Field\SwitchField::class,
            'text'           => Field\Text::class,
            'textarea'       => Field\Textarea::class,
            'time'           => Field\Time::class,
            'timeRange'      => Field\TimeRange::class,
            'url'            => Field\Url::class,
            'year'           => Field\Year::class,
            'html'           => Field\Html::class,
            'tags'           => Field\Tags::class,
            'icon'           => Field\Icon::class,
            'multipleFile'   => Field\MultipleFile::class,
            'multipleImage'  => Field\MultipleImage::class,
            'captcha'        => Field\Captcha::class,
            'listbox'        => Field\Listbox::class,
            'table'          => Field\Table::class,
        ];

        foreach ($map as $abstract => $class) {
            static::extend($abstract, $class);
        }
    }
997777
def register(self, cls):
        """"""
        doc_type = cls.search_objects.mapping.doc_type

        self.all_models[doc_type] = cls
        base_class = cls.get_base_class()
        if base_class not in self.families:
            self.families[base_class] = {}
        self.families[base_class][doc_type] = cls

        if cls.search_objects.mapping.index not in self.indexes:
            self.indexes[cls.search_objects.mapping.index] = []

        self.indexes[cls.search_objects.mapping.index].append(cls)
452898
def register_calculator_view(request):
    """"""
    if request.method == "POST":
        form = CalculatorRegistrationForm(request.POST)
        logger.debug(form)
        if form.is_valid():
            obj = form.save()
            obj.user = request.user
            obj.save()
            messages.success(request, "Successfully added calculator.")
            return redirect("itemreg")
        else:
            messages.error(request, "Error adding calculator.")
    else:
        form = CalculatorRegistrationForm()
    return render(request, "itemreg/register_form.html", {"form": form, "action": "add", "type": "calculator", "form_route": "itemreg_calculator"})
1065461
protected function registerBindings()
    {
        $this->app->singleton(PageHeaderDirective::class, PageHeaderDirective::class);
        $this->app->singleton(TooltipDirective::class, TooltipDirective::class);
        $this->app->singleton(SearchEngine::class, LocalSearch::class);
    }
319580
public static function registerBuiltinFields()
    {
        $map = [
            'button'         => \Ekipisi\Admin\Form\Field\Button::class,
            'checkbox'       => \Ekipisi\Admin\Form\Field\Checkbox::class,
            'color'          => \Ekipisi\Admin\Form\Field\Color::class,
            'currency'       => \Ekipisi\Admin\Form\Field\Currency::class,
            'date'           => \Ekipisi\Admin\Form\Field\Date::class,
            'dateRange'      => \Ekipisi\Admin\Form\Field\DateRange::class,
            'datetime'       => \Ekipisi\Admin\Form\Field\Datetime::class,
            'dateTimeRange'  => \Ekipisi\Admin\Form\Field\DatetimeRange::class,
            'datetimeRange'  => \Ekipisi\Admin\Form\Field\DatetimeRange::class,
            'decimal'        => \Ekipisi\Admin\Form\Field\Decimal::class,
            'display'        => \Ekipisi\Admin\Form\Field\Display::class,
            'divider'        => \Ekipisi\Admin\Form\Field\Divide::class,
            'divide'         => \Ekipisi\Admin\Form\Field\Divide::class,
            'embeds'         => \Ekipisi\Admin\Form\Field\Embeds::class,
            'editor'         => \Ekipisi\Admin\Form\Field\Editor::class,
            'email'          => \Ekipisi\Admin\Form\Field\Email::class,
            'file'           => \Ekipisi\Admin\Form\Field\File::class,
            'hasMany'        => \Ekipisi\Admin\Form\Field\HasMany::class,
            'hidden'         => \Ekipisi\Admin\Form\Field\Hidden::class,
            'id'             => \Ekipisi\Admin\Form\Field\Id::class,
            'image'          => \Ekipisi\Admin\Form\Field\Image::class,
            'ip'             => \Ekipisi\Admin\Form\Field\Ip::class,
            'map'            => \Ekipisi\Admin\Form\Field\Map::class,
            'mobile'         => \Ekipisi\Admin\Form\Field\Mobile::class,
            'month'          => \Ekipisi\Admin\Form\Field\Month::class,
            'multipleSelect' => \Ekipisi\Admin\Form\Field\MultipleSelect::class,
            'number'         => \Ekipisi\Admin\Form\Field\Number::class,
            'password'       => \Ekipisi\Admin\Form\Field\Password::class,
            'radio'          => \Ekipisi\Admin\Form\Field\Radio::class,
            'rate'           => \Ekipisi\Admin\Form\Field\Rate::class,
            'select'         => \Ekipisi\Admin\Form\Field\Select::class,
            'slider'         => \Ekipisi\Admin\Form\Field\Slider::class,
            'switch'         => \Ekipisi\Admin\Form\Field\SwitchField::class,
            'text'           => \Ekipisi\Admin\Form\Field\Text::class,
            'textarea'       => \Ekipisi\Admin\Form\Field\Textarea::class,
            'time'           => \Ekipisi\Admin\Form\Field\Time::class,
            'timeRange'      => \Ekipisi\Admin\Form\Field\TimeRange::class,
            'url'            => \Ekipisi\Admin\Form\Field\Url::class,
            'year'           => \Ekipisi\Admin\Form\Field\Year::class,
            'html'           => \Ekipisi\Admin\Form\Field\Html::class,
            'tags'           => \Ekipisi\Admin\Form\Field\Tags::class,
            'icon'           => \Ekipisi\Admin\Form\Field\Icon::class,
            'multipleFile'   => \Ekipisi\Admin\Form\Field\MultipleFile::class,
            'multipleImage'  => \Ekipisi\Admin\Form\Field\MultipleImage::class,
            'captcha'        => \Ekipisi\Admin\Form\Field\Captcha::class,
            'listbox'        => \Ekipisi\Admin\Form\Field\Listbox::class,
        ];

        foreach ($map as $abstract => $class) {
            static::extend($abstract, $class);
        }
    }
1073996
public function register()
    {
        $this->registerBindings();

        $this->createAliases();

        // Bootstrap Form and HTML Builders
        $this->bootstrapFormAndHtmlBuilders();

        // Merge the config values so they don't have to have a complete configuration
        $this->mergeConfigFrom(__DIR__.'/../config/bumble.php', 'bumble');

        // Register the default views
        $this->loadViewsFrom(__DIR__ . '/../resources/views/', 'bumble');
    }
590325
static function registerForm (Form $form)
    {
        if (!in_array($form, self::$forms))
            array_push(self::$forms, $form);
    }