text:
<?php

namespace ImboUnitTest\Auth\AccessControl\Adapter;

use Imbo\Auth\AccessControl\Adapter\MongoDB,
    MongoException;

/**
 * @covers Imbo\Auth\AccessControl\Adapter\MongoDB
 * @group unit
 * @group mongodb
 */
class MongoDBTest extends \PHPUnit_Framework_TestCase {
    /**
     * @var MongoClient
     */
    private $client;

    /**
     * @var MongoCollection
     */
    private $aclCollection;

    /**
     * @var MongoCollection
     */
    private $aclGroupCollection;

    /**
     * @var MongoDB
     */
    private $adapter;

    /**
     * Set up
     */
    public function setUp() {
        $this->client = $this->getMock('MongoClient');
        $this->aclCollection = $this->getMockBuilder('MongoCollection')->disableOriginalConstructor()->getMock();
        $this->aclGroupCollection = $this->getMockBuilder('MongoCollection')->disableOriginalConstructor()->getMock();
        $this->adapter = new MongoDB(null, $this->client, $this->aclCollection, $this->aclGroupCollection);
    }

    /**
     * Tear down
     */
    public function tearDown() {
        $this->adapter = $this->client = $this->aclCollection = $this->aclGroupCollection = null;
    }

    /**
     * @expectedException Imbo\Exception\DatabaseException
     * @expectedExceptionCode 500
     * @expectedExceptionMessage Could not insert key into database
     */
    public function testThrowsExceptionWhenUnableToAddKeyPair() {
        $this->aclCollection
            ->expects($this->once())
            ->method('insert')
            ->with(['publicKey' => 'public', 'privateKey' => 'private', 'acl' => []])
            ->will($this->throwException(new MongoException()));
        $this->adapter->addKeyPair('public', 'private');
    }

    /**
     * @expectedException Imbo\Exception\DatabaseException
     * @expectedExceptionCode 500
     * @expectedExceptionMessage Could not delete key from database
     */
    public function testThrowsExceptionWhenUnableToDeleteKeyPair() {
        $this->aclCollection
            ->expects($this->once())
            ->method('remove')
            ->with(['publicKey' => 'public'])
            ->will($this->throwException(new MongoException()));
        $this->adapter->deletePublicKey('public');
    }

    /**
     * @expectedException Imbo\Exception\DatabaseException
     * @expectedExceptionCode 500
     * @expectedExceptionMessage Could not update key in database
     */
    public function testThrowsExceptionWhenUnableToUpdatePrivateKey() {
        $this->aclCollection
            ->expects($this->once())
            ->method('update')
            ->with(['publicKey' => 'public'], ['$set' => ['privateKey' => 'private']])
            ->will($this->throwException(new MongoException()));
        $this->adapter->updatePrivateKey('public', 'private');
    }

    /**
     * @expectedException Imbo\Exception\DatabaseException
     * @expectedExceptionCode 500
     * @expectedExceptionMessage Could not update rule in database
     */
    public function testThrowsExceptionWhenUnableToAddAccessRule() {
        $this->aclCollection
            ->expects($this->once())
            ->method('update')
            ->with(['publicKey' => 'public'], $this->isType('array'))
            ->will($this->throwException(new MongoException()));
        $this->adapter->addAccessRule('public', []);
    }

    /**
     * @expectedException Imbo\Exception\DatabaseException
     * @expectedExceptionCode 500
     * @expectedExceptionMessage Could not delete rule from database
     */
    public function testThrowsExceptionWhenUnableToDeleteAccessRule() {
        $this->aclCollection
            ->expects($this->once())
            ->method('update')
            ->with(['publicKey' => 'public'], $this->isType('array'))
            ->will($this->throwException(new MongoException()));
        $this->adapter->deleteAccessRule('public', '49a7011a05c677b9a916612a');
    }

    /**
     * @expectedException Imbo\Exception\DatabaseException
     * @expectedExceptionCode 500
     * @expectedExceptionMessage Could not add resource group to database
     */
    public function testThrowsExceptionWhenUnableToAddResourceGroup() {
        $this->aclGroupCollection
            ->expects($this->once())
            ->method('insert')
            ->with(['name' => 'name', 'resources' => []])
            ->will($this->throwException(new MongoException()));
        $this->adapter->addResourceGroup('name', []);
    }

    /**
     * @expectedException Imbo\Exception\DatabaseException
     * @expectedExceptionCode 500
     * @expectedExceptionMessage Could not update resource group in database
     */
    public function testThrowsExceptionWhenUnableToUpdateResourceGroup() {
        $this->aclGroupCollection
            ->expects($this->once())
            ->method('update')
            ->with(['name' => 'name'], ['$set' => ['resources' => []]])
            ->will($this->throwException(new MongoException()));
        $this->adapter->updateResourceGroup('name', []);
    }

    /**
     * @expectedException Imbo\Exception\DatabaseException
     * @expectedExceptionCode 500
     * @expectedExceptionMessage Could not delete resource group from database
     */
    public function testThrowsExceptionWhenUnableToDeleteResourceGroup() {
        $this->aclGroupCollection
            ->expects($this->once())
            ->method('remove')
            ->with(['name' => 'name'])
            ->will($this->throwException(new MongoException()));
        $this->adapter->deleteResourceGroup('name');
    }

    /**
     * @expectedException Imbo\Exception\DatabaseException
     * @expectedExceptionCode 500
     * @expectedExceptionMessage Could not delete resource group from database
     */
    public function testThrowsExceptionWhenUnableToRemoveAclFromGroup() {
        $this->aclGroupCollection
            ->expects($this->once())
            ->method('remove')
            ->with(['name' => 'name'])
            ->will($this->returnValue(['ok' => true]));

        $this->aclCollection
            ->expects($this->once())
            ->method('update')
            ->with(['acl.group' => 'name'], ['$pull' => ['acl' => ['group' => 'name']]])
            ->will($this->throwException(new MongoException()));

        $this->adapter->deleteResourceGroup('name');
    }

    /**
     * @expectedException Imbo\Exception\DatabaseException
     * @expectedExceptionCode 500
     * @expectedExceptionMessage Could not select collection
     */
    public function testThrowsExceptionWhenNotAbleToGetAclCollection() {
        $adapter = new MongoDB(['databaseName' => 'somename'], $this->client);
        $this->client
            ->expects($this->once())
            ->method('selectCollection')
            ->with('somename', 'accesscontrol')
            ->will($this->throwException(new MongoException()));
        $adapter->addKeyPair('public', 'private');
    }

    /**
     * @expectedException Imbo\Exception\DatabaseException
     * @expectedExceptionCode 500
     * @expectedExceptionMessage Could not select collection
     */
    public function testThrowsExceptionWhenNotAbleToGetAclGroupCollection() {
        $adapter = new MongoDB(['databaseName' => 'somename'], $this->client);
        $this->client
            ->expects($this->once())
            ->method('selectCollection')
            ->with('somename', 'accesscontrolgroup')
            ->will($this->throwException(new MongoException()));
        $adapter->groupExists('name');
    }

    /**
     * @expectedException Imbo\Exception\DatabaseException
     * @expectedExceptionCode 500
     * @expectedExceptionMessage Could not connect to database
     */
    public function testThrowsExceptionWhenNotAbleToGetMongoClient() {
        $adapter = new MongoDB([
            'server' => 'foobar',
        ]);
        $adapter->getGroup('name');
    }
}


text:
using System;
using Android.App;
using Android.Content;

namespace MonoDroid.Dialog
{
    public class DateTimeElement : StringElement
    {
        public DateTime DateValue
        {
            get { return DateTime.Parse(Value); }
            set { Value = Format(value); }
        }

        public DateTimeElement(string caption, DateTime date)
            : base(caption)
        {
            DateValue = date;
        }

        public DateTimeElement(string caption, DateTime date, int layoutId)
            : base(caption, layoutId)
        {
            DateValue = date;
        }

        public virtual string Format(DateTime dt)
        {
            return dt.ToShortDateString() + " " + dt.ToShortTimeString();
        }
    }

    public class DateElement : DateTimeElement
    {
        public DateElement(string caption, DateTime date)
            : base(caption, date)
        {
            this.Tapped = delegate { EditDate(); };
        }

        public DateElement(string caption, DateTime date, int layoutId)
            : base(caption, date, layoutId)
        {
            this.Tapped = delegate { EditDate(); };
        }

        public override string Format(DateTime dt)
        {
            return dt.ToShortDateString();
        }

        // the event received when the user "sets" the date in the dialog
        void OnDateSet(object sender, DatePickerDialog.DateSetEventArgs e)
        {
            DateTime current = DateValue;
            DateValue = new DateTime(e.Date.Year, e.Date.Month, e.Date.Day, current.Hour, current.Minute, 0);
        }

        private void EditDate()
        {
            Context context = GetContext();
            if (context == null)
            {
                Android.Util.Log.Warn("DateElement", "No Context for Edit");
                return;
            }
            DateTime val = DateValue;
            new DatePickerDialog(context, OnDateSet, val.Year, val.Month - 1, val.Day).Show();
        }
    }

    public class TimeElement : DateTimeElement
    {
        public TimeElement(string caption, DateTime date)
            : base(caption, date)
        {
            this.Tapped = delegate { EditDate(); };
        }

        public TimeElement(string caption, DateTime date, int layoutId)
            : base(caption, date, layoutId)
        {
            this.Tapped = delegate { EditDate(); };
        }

        public override string Format(DateTime dt)
        {
            return dt.ToShortTimeString();
        }

        // the event received when the user "sets" the date in the dialog
        void OnDateSet(object sender, TimePickerDialog.TimeSetEventArgs e)
        {
            DateTime current = DateValue;
            DateValue = new DateTime(current.Year, current.Month, current.Day, e.HourOfDay, e.Minute, 0);
        }

        private void EditDate()
        {
            Context context = GetContext();
            if (context == null)
            {
                Android.Util.Log.Warn("TimeElement", "No Context for Edit");
                return;
            }
            DateTime val = DateValue;
            // TODO: get the current time setting for thge 24 hour clock
            new TimePickerDialog(context, OnDateSet, val.Hour, val.Minute, false).Show();
        }
    }
}

redpajama_set_name: RedPajamaGithub


text:
var andJS = (function() {

    'use strict';

    var undefined;

    function andJS() {

        var
        _stack = [],

        _typeOf = function(item, type) {
            if (typeof item === type) return true;
            if (type === 'array' && item.prototype && item.prototype.toString.call(this) === '[object Array]') return true;
            if (type === 'HTMLElement') {
                try {
                    return obj instanceof HTMLElement;
                } catch(e){
                    return /\HTML.+Element/.test(item.constructor.toString());
                }
            }
            return false;
        },
        _console = function(type, args) {
            if (console && console[type]) {
                console[type].apply(console, args);
            }
        },
        _log = function() {
            _console('log', arguments);
            return this;
        },
        _warn = function() {
            _console('warn', arguments);
            return this;
        },
        _debug = function() {
            _console('debug', arguments)
            return this;
        },
        _error = function() {
            _console('error', arguments)
            return this;
        },

        _add = function(_el) {
            _stack.push(_el);
        },
        _addFromList = function() {
            _add(arguments[1]);
        },
        _last = function() {
          return _stack.slice(-1).pop();
        },
        _each = function(items, callback, context) {
            for (var n in items) {
                if (items.hasOwnProperty(n)) {
                    callback.call(context, n, items[n]);
                }
            }
            return this;
        },
        _prop = function(prop, value) {
            if (typeof prop === 'object') {
                _each(prop, _prop, this);
            } else {
                this[prop] = value;
            }
        },
        _attr = function(attr, value) {
            if (typeof attr === 'object') {
                _each(attr, _attr, this);
            } else {
                if (attr === 'text') {
                    this.appendChild(
                        document.createTextNode(value));
                } else {
                    this.setAttribute(attr, value);
                }
            }
        },
        _append = function(tag, attrs) {
            var _node = document.createElement(tag);
            _attr.call(_node, attrs);
            this.appendChild(_node);
        },

        fns = {
            go: function() {
                _each(arguments, function(i, _el) {
                    _add(_el);
                });
                return this;
            },
            id: function(_id) {
                var _el = document.getElementById(_id);
                if (_el) _add(_el);
                return this;
            },
            tags: function(_tagname) {
                _add(document.getElementsByTagName(_tagname));
                return this;
            },
            query: function(_query) {
                if (document.querySelectorAll) {
                    _add(document.querySelectorAll(_query));
                }
                return this;
            },
            html: function() {
                var _el = _last();
                return _el ? _el.innerHTML : '';
            },
            append: function(tag, attrs) {
                var last = _last();
                if (_typeOf(last, 'HTMLElement')) {
                    _append.call(last, tag, attrs);
                } else {
                    _each(last, function() {
                        _append.call(arguments[1], tag, attrs);
                    });
                }
                return this;
            },
            jsonp: function(url, fn) {
                fns.tags('head').append('script', {
                    src: url + (url.indexOf('?') < 0 ? '?' : '&') + 'jsonp=' + fn
                });
                _stack.pop();
                return this;
            },
            attr: function(attr, value){
                var last = _last();
                if (_typeOf(last, 'HTMLElement')) {
                    _attr.call(last, attr, value);
                } else {
                    _each(last, function() {
                        _attr.call(arguments[1], attr, value);
                    });
                }
                return this;
            },
            prop: function(prop, value){
                var last = _last();
                if (_typeOf(last, 'HTMLElement')) {
                    _prop.call(last, prop, value);
                } else {
                    _each(last, function() {
                        _prop.call(arguments[1], prop, value);
                    });
                }
                return this;
            },
            up: function() {
                _stack.pop();
                return this;
            },
            each: _each,
            log: _log,
            warn: _warn,
            typeOf: _typeOf
        };

        return fns;
    }

    return new andJS();

})();


text:
package jadx.tests.integration.generics;

import java.util.List;

import org.junit.jupiter.api.Test;

import jadx.core.dex.nodes.ClassNode;
import jadx.tests.api.IntegrationTest;

import static org.hamcrest.CoreMatchers.containsString;
import static org.hamcrest.MatcherAssert.assertThat;

public class TestGenerics3 extends IntegrationTest {

	public static class TestCls {

		public static void mthExtendsArray(List<? extends byte[]> list) {
		}

		public static void mthSuperArray(List<? super int[]> list) {
		}

		public static void mthSuperInteger(List<? super Integer> list) {
		}

		public static void mthExtendsString(List<? super String> list) {
		}
	}

	@Test
	public void test() {
		ClassNode cls = getClassNode(TestCls.class);
		String code = cls.getCode().toString();

		assertThat(code, containsString("mthExtendsArray(List<? extends byte[]> list)"));
		assertThat(code, containsString("mthSuperArray(List<? super int[]> list)"));
		assertThat(code, containsString("mthSuperInteger(List<? super Integer> list)"));
		assertThat(code, containsString("mthExtendsString(List<? super String> list)"));
	}
}


text:
package hsup

import (
	"fmt"
	"log"
	"os"
	"syscall"
	"time"

	"path/filepath"

	"github.com/fsouza/go-dockerclient"
)

type DockerDynoDriver struct {
	d *Docker
}

func (dd *DockerDynoDriver) Build(release *Release) error {
	if release.stack != "cedar-14" {
		return fmt.Errorf("only cedar-14 is supported, but the "+
			"application uses the %q stack", release.stack)
	}

	if err := dd.connectDocker(); err != nil {
		return err
	}

	// TODO: map release.stack -> docker image name
	stack := "heroku/cedar:14"
	si, err := dd.d.StackStat(stack)
	if err != nil {
		return err
	}
	if si == nil {
		log.Fatalln("Stack not found:", stack)
	}

	imageName, err := dd.d.BuildSlugImage(si, release)
	if err != nil {
		log.Fatalln("could not build image:", err)
	}
	log.Println("Built image successfully")

	release.imageName = imageName
	return nil
}

func (dd *DockerDynoDriver) Start(ex *Executor) error {
	hs := Startup{
		App: AppSerializable{
			Version: ex.Release.version,
			Name:    ex.Release.appName,
			Env:     ex.Release.config,
			Stack:   ex.Release.stack,
			Processes: []FormationSerializable{
				{
					FArgs:     ex.Args,
					FQuantity: 1,
					FType:     ex.ProcessType,
				},
			},
		},
		OneShot:     true,
		StartNumber: ex.ProcessID,
		Action:      Start,
		Driver:      &AbsPathDynoDriver{},
		LogplexURL:  ex.logplexURLString(),
	}

	// attach a timestamp as some extra entropy because container names must be
	// unique
	name := fmt.Sprintf("%v.%v", ex.Name(), time.Now().Unix())
	vols := make(map[string]struct{})
	vols["/hsup"] = struct{}{}
	for _, inside := range ex.Binds {
		vols[inside] = struct{}{}
	}

	container, err := dd.d.c.CreateContainer(docker.CreateContainerOptions{
		Name: name,
		Config: &docker.Config{
			Cmd:          []string{"setuidgid", "app", "/hsup"},
			Env:          []string{"HSUP_CONTROL_GOB=" + hs.ToBase64Gob()},
			Image:        ex.Release.imageName,
			Volumes:      vols,
			ExposedPorts: map[docker.Port]struct{}{docker.Port("5000/tcp"): {}},
		},
	})
	if err != nil {
		log.Fatalln("could not create container:", err)
	}
	ex.container = container

	where, err := filepath.Abs(linuxAmd64Path())
	if err != nil {
		return err
	}

	err = dd.d.c.StartContainer(ex.container.ID, &docker.HostConfig{
		Binds:           append([]string{where + ":/hsup"}, ex.bindPairs()...),
		PublishAllPorts: true,
	})
	if err != nil {
		log.Fatal(err)
	}

	go dd.d.c.Logs(docker.LogsOptions{
		Container:    container.ID,
		Stdout:       true,
		Stderr:       true,
		Follow:       true,
		OutputStream: os.Stdout,
	})

	return nil
}

func (dd *DockerDynoDriver) Wait(ex *Executor) (s *ExitStatus) {
	code, err := dd.d.c.WaitContainer(ex.container.ID)
	return &ExitStatus{Code: code, Err: err}
}

func (dd *DockerDynoDriver) Stop(ex *Executor) error {
	log.Println("Stopping container for", ex.Name())
	dd.d.c.KillContainer(docker.KillContainerOptions{
		ID:     ex.container.ID,
		Signal: docker.Signal(syscall.SIGTERM)})
	return dd.d.c.StopContainer(ex.container.ID, 10)
}

func (dd *DockerDynoDriver) connectDocker() error {
	if dd.d == nil {
		dd.d = &Docker{}
		if err := dd.d.Connect(); err != nil {
			dd.d = nil
			return err
		}
	}

	return nil
}


text:
package hu.scelightapi.service;

import hu.scelightapi.IServices;
import hu.scelightapi.gui.comp.ICheckBoxMenuItem;
import hu.scelightapi.gui.comp.IIndicatorTextArea;
import hu.scelightapi.gui.comp.IList;
import hu.scelightapi.gui.comp.IMenu;
import hu.scelightapi.gui.comp.IMenuItem;
import hu.scelightapi.gui.comp.IPasswordField;
import hu.scelightapi.gui.comp.IPopupMenu;
import hu.scelightapi.gui.comp.ITabbedPane;
import hu.scelightapi.gui.comp.ITemplateField;
import hu.scelightapi.gui.comp.IToolBarForList;
import hu.scelightapi.gui.comp.IToolBarForTree;
import hu.scelightapi.gui.overlaycard.IConfigPopupBuilder;
import hu.scelightapi.gui.overlaycard.IOverlayCard;
import hu.scelightapi.gui.overlaycard.OverlayCardParams;
import hu.scelightapi.gui.setting.ISettingsGui;
import hu.scelightapibase.action.IAction;
import hu.scelightapibase.gui.comp.IBorderPanel;
import hu.scelightapibase.gui.comp.IBrowser;
import hu.scelightapibase.gui.comp.IButton;
import hu.scelightapibase.gui.comp.ICheckBox;
import hu.scelightapibase.gui.comp.IColorIcon;
import hu.scelightapibase.gui.comp.IDialog;
import hu.scelightapibase.gui.comp.IFileChooser;
import hu.scelightapibase.gui.comp.IGridBagPanel;
import hu.scelightapibase.gui.comp.IHelpIcon;
import hu.scelightapibase.gui.comp.IIndicatorTextField;
import hu.scelightapibase.gui.comp.ILabel;
import hu.scelightapibase.gui.comp.ILink;
import hu.scelightapibase.gui.comp.IModestLabel;
import hu.scelightapibase.gui.comp.IPathField;
import hu.scelightapibase.gui.comp.IProgressBar;
import hu.scelightapibase.gui.comp.IScrollPane;
import hu.scelightapibase.gui.comp.ISpinner;
import hu.scelightapibase.gui.comp.ISplitPane;
import hu.scelightapibase.gui.comp.IStatusLabel;
import hu.scelightapibase.gui.comp.IStatusLabel.IStatusType;
import hu.scelightapibase.gui.comp.ITextArea;
import hu.scelightapibase.gui.comp.ITextField;
import hu.scelightapibase.gui.comp.ITipIcon;
import hu.scelightapibase.gui.comp.IToolBar;
import hu.scelightapibase.gui.comp.IToolBarForTable;
import hu.scelightapibase.gui.comp.ITree;
import hu.scelightapibase.gui.comp.combobox.IComboBox;
import hu.scelightapibase.gui.comp.multipage.IMultiPageComp;
import hu.scelightapibase.gui.comp.multipage.IPage;
import hu.scelightapibase.gui.comp.multipage.IPageCompCreator;
import hu.scelightapibase.gui.comp.table.ITable;
import hu.scelightapibase.gui.comp.table.renderer.IBarCodeView;
import hu.scelightapibase.gui.comp.table.renderer.IProgressBarView;
import hu.scelightapibase.gui.icon.IRIcon;
import hu.scelightapibase.util.IRHtml;
import hu.scelightapibase.util.gui.IRenderablePair;
import hu.scelightapibase.util.iface.Consumer;

import java.awt.Color;
import java.awt.Component;
import java.awt.Frame;
import java.awt.event.ActionListener;
import java.awt.event.MouseEvent;
import java.net.URL;
import java.nio.file.Path;
import java.util.List;
import java.util.Set;
import java.util.Vector;

import javax.swing.Icon;
import javax.swing.JComponent;
import javax.swing.JSplitPane;
import javax.swing.KeyStroke;
import javax.swing.SpinnerModel;
import javax.swing.SpinnerNumberModel;
import javax.swing.tree.TreeNode;

/**
 * (Swing) GUI factory interface.
 *
 *

 * Used to create new instances of GUI API interfaces.
 *

 *
 *

 * For a consistent UI and user experience it is strongly recommended to use extended components offered here whenever possible. Also these extended components
 * follow the user interface related settings.

 * You can mix extended components offered by the API and "basic" Swing components, but by using basic Swing components you'll lose the extra functionality
 * provided by the extended components - and future ones that will be added in the future.
 *

 *
 *

 * For components that are initialized from setting values or are bound to them, please see {@link ISettingsGui}.
 *

 *
 * @author Andras Belicza
 *
 * @see IFactory
 * @see ISettingsGui
 */
public interface IGuiFactory {

	/**
	 * Creates a new {@link ILabel}.
	 *
	 * @return a new {@link ILabel}
	 */
	ILabel newLabel();

	/**
	 * Creates a new {@link ILabel}.
	 *
	 * @param text text of the label
	 * @return a new {@link ILabel}
	 */
	ILabel newLabel( String text );

	/**
	 * Creates a new {@link ILabel}.
	 *
	 * @param text text of the label
	 * @param halignment horizontal alignment; one of SwingConstants: LEFT, CENTER, RIGHT, LEADING or TRAILING
	 * @return a new {@link ILabel}
	 */
	ILabel newLabel( String text, int halignment );

	/**
	 * Creates a new {@link ILabel}.
	 *
	 * @param icon icon of the label
	 * @return a new {@link ILabel}
	 */
	ILabel newLabel( Icon icon );

	/**
	 * Creates a new {@link ILabel}.
	 *
	 * @param text text of the label
	 * @param icon icon of the label
	 * @return a new {@link ILabel}
	 */
	ILabel newLabel( String text, Icon icon );

	/**
	 * Creates a new {@link ILabel}.
	 *
	 * @param text text of the label
	 * @param icon icon of the label
	 * @param halignment horizontal alignment; one of SwingConstants: LEFT, CENTER, RIGHT, LEADING or TRAILING
	 * @return a new {@link ILabel}
	 */
	ILabel newLabel( String text, Icon icon, int halignment );

	/**
	 * Creates a new {@link IRIcon} from the specified image location.
	 *
	 *

	 * Created and returned {@link IRIcon}s should always be cached for performance reasons, that way the image resource represented by the {@link IRIcon} can
	 * be shared and reused.
	 *

	 *
	 *

	 * Supported image formats include PNG, JPEG, GIF.
	 *

	 *
	 * @param url the URL for the image to create an {@link IRIcon} from
	 * @return a new {@link IRIcon}
	 * @see IRIcon
	 */
	IRIcon newRIcon( URL url );

	/**
	 * Creates a new {@link IRHtml}.
	 *
	 * @param title title of the HTML template
	 * @param resource HTML template resource
	 * @param params param name - param value pairs to be substituted in the HTML template;

	 *            param names must be in raw format, they will be prepended with "${" and postpended with "}"
	 * @return a new {@link IRHtml}
	 * @see IRHtml
	 */
	IRHtml newRHtml( String title, URL resource, String... params );

	/**
	 * Creates a new {@link IRHtml}.
	 *
	 * @param title title of the HTML template
	 * @param resource HTML template resource
	 * @param htmlParams collection of HTML param names, values of these parameters are treated as HTML and are not escaped
	 * @param params param name - param value pairs to be substituted in the HTML template;

	 *            param names must be in raw format, they will be prepended with "${" and postpended with "}"
	 * @return a new {@link IRHtml}
	 * @see IRHtml
	 */
	IRHtml newRHtml( String title, URL resource, Set< String > htmlParams, String... params );

	/**
	 * Creates a new {@link IHelpIcon}.
	 *
	 * @param helpRhtml html template resource of the help content
	 * @return a new {@link IHelpIcon}
	 */
	IHelpIcon newHelpIcon( IRHtml helpRhtml );

	/**
	 * Creates a new {@link IHelpIcon}.
	 *
	 * @param helpRhtml html template resource of the help content
	 * @param stressed tells if the help icon's appearance should be garish, stressed
	 * @return a new {@link IHelpIcon}
	 */
	IHelpIcon newHelpIcon( IRHtml helpRhtml, boolean stressed );

	/**
	 * Creates a new {@link ITipIcon}.
	 *
	 * @param tipRhtml html template resource of the tip content
	 * @return a new {@link ITipIcon}
	 */
	ITipIcon newTipIcon( IRHtml tipRhtml );

	/**
	 * Creates a new {@link ILink} with no URL and no target action.
	 *
	 * @return a new {@link ILink}
	 */
	ILink newLink();

	/**
	 * Creates a new {@link ILink} with no URL or target action.
	 *

	 * Basically this is a link-styled {@link ILabel}.
	 *

	 *
	 * @param text text of the link
	 * @return a new {@link ILink}
	 */
	ILink newLink( String text );

	/**
	 * Creates a new {@link ILink} which opens the specified URL in the user's default browser when clicked.
	 *
	 * @param text text of the link
	 * @param url {@link URL} to be opened when clicked
	 * @return a new {@link ILink}
	 */
	ILink newLink( String text, URL url );

	/**
	 * Creates a new {@link ILink} which forwards mouse click events to the specified {@link Consumer}.
	 *
	 * @param text text of the link
	 * @param consumer consumer to be called when clicked
	 * @return a new {@link ILink}
	 */
	ILink newLink( String text, Consumer< MouseEvent > consumer );

	/**
	 * Creates a new {@link ILink} which forwards mouse click events to the specified {@link Consumer} and opens the specified URL in the user's default browser
	 * when clicked.
	 *
	 * @param text text of the link
	 * @param url {@link URL} to be opened when clicked
	 * @param consumer consumer to be called when clicked
	 * @return a new {@link ILink}
	 */
	ILink newLink( String text, URL url, Consumer< MouseEvent > consumer );

	/**
	 * Creates a new {@link IAction}.
	 *
	 * @param ricon optional ricon of the action
	 * @param text text of the action
	 * @param listener action listener to be called when action is performed
	 * @return a new {@link IAction}
	 */
	IAction newAction( IRIcon ricon, String text, ActionListener listener );

	/**
	 * Creates a new {@link IAction}.
	 *
	 * @param ricon optional ricon of the action
	 * @param text text of the action
	 * @param comp component to bind the action's setting change listener to; basically in this case the lifetime of the scl will be bound to the specified
	 *            component's lifetime
	 * @param listener action listener to be called when action is performed
	 * @return a new {@link IAction}
	 */
	IAction newAction( IRIcon ricon, String text, JComponent comp, ActionListener listener );

	/**
	 * Creates a new {@link IAction}.
	 *
	 * @param keyStroke optional hotkey of the action
	 * @param ricon optional ricon of the action
	 * @param text text of the action
	 * @param listener action listener to be called when action is performed
	 * @return a new {@link IAction}
	 */
	IAction newAction( KeyStroke keyStroke, IRIcon ricon, String text, ActionListener listener );

	/**
	 * Creates a new {@link IAction}.
	 *
	 * @param keyStroke optional hotkey of the action
	 * @param ricon optional ricon of the action
	 * @param text text of the action
	 * @param comp component to bind the action's setting change listener to; basically in this case the lifetime of the scl will be bound to the specified
	 *            component's lifetime
	 * @param listener action listener to be called when action is performed
	 * @return a new {@link IAction}
	 */
	IAction newAction( KeyStroke keyStroke, IRIcon ricon, String text, JComponent comp, ActionListener listener );

	/**
	 * Creates a new {@link IButton}.
	 *
	 * @return a new {@link IButton}
	 */
	IButton newButton();

	/**
	 * Creates a new {@link IButton}.
	 *
	 * @param text text of the button
	 * @return a new {@link IButton}
	 */
	IButton newButton( String text );

	/**
	 * Creates a new {@link IButton}.
	 *
	 * @param icon icon of the button
	 * @return a new {@link IButton}
	 */
	IButton newButton( Icon icon );

	/**
	 * Creates a new {@link IButton}.
	 *
	 * @param text text of the button
	 * @param icon icon of the button
	 * @return a new {@link IButton}
	 */
	IButton newButton( String text, Icon icon );

	/**
	 * Creates a new {@link IButton}.
	 *
	 * @param action action to configure the button from
	 * @return a new {@link IButton}
	 */
	IButton newButton( IAction action );

	/**
	 * Creates a new {@link ITextField}.
	 *
	 * @return a new {@link ITextField}
	 */
	ITextField newTextField();

	/**
	 * Creates a new {@link ITextField}.
	 *
	 * @param clearByEsc tells if text field should be cleared when the ESC key is pressed
	 * @return a new {@link ITextField}
	 */
	ITextField newTextField( boolean clearByEsc );

	/**
	 * Creates a new {@link ITextField}.
	 *
	 * @param text initial text of the text field
	 * @return a new {@link ITextField}
	 */
	ITextField newTextField( String text );

	/**
	 * Creates a new {@link ITextField}.
	 *
	 * @param columns the number of columns to use to calculate the preferred width; if columns is set to zero, the preferred width will be whatever naturally
	 *            results from the component implementation
	 * @return a new {@link ITextField}
	 */
	ITextField newTextField( int columns );

	/**
	 * Creates a new {@link ITextField}.
	 *
	 * @param text text of the check box
	 * @param columns the number of columns to use to calculate the preferred width; if columns is set to zero, the preferred width will be whatever naturally
	 *            results from the component implementation
	 * @return a new {@link ITextField}
	 */
	ITextField newTextField( String text, int columns );

	/**
	 * Creates a new {@link ITextField}.
	 *
	 * @param text text of the check box
	 * @param columns the number of columns to use to calculate the preferred width; if columns is set to zero, the preferred width will be whatever naturally
	 *            results from the component implementation
	 * @param clearByEsc tells if text field should be cleared when the ESC key is pressed
	 * @return a new {@link ITextField}
	 */
	ITextField newTextField( String text, int columns, boolean clearByEsc );

	/**
	 * Creates a new {@link IIndicatorTextField}.
	 *
	 * @return a new {@link IIndicatorTextField}
	 */
	IIndicatorTextField newIndicatorTextField();

	/**
	 * Creates a new {@link IIndicatorTextField}.
	 *
	 * @param text initial text to be set
	 * @return a new {@link IIndicatorTextField}
	 */
	IIndicatorTextField newIndicatorTextField( String text );

	/**
	 * Creates a new {@link ITextArea}.
	 *
	 * @return a new {@link ITextArea}
	 */
	ITextArea newTextArea();

	/**
	 * Creates a new {@link ITextArea}.
	 *
	 * @param text initial text of the text area
	 * @return a new {@link ITextArea}
	 */
	ITextArea newTextArea( String text );

	/**
	 * Creates a new {@link ITextArea}.
	 *
	 * @param text initial text of the text area
	 * @param rows the number of rows to use to calculate the preferred height
	 * @param columns the number of columns to use to calculate the preferred width
	 * @return a new {@link ITextArea}
	 */
	ITextArea newTextArea( String text, int rows, int columns );

	/**
	 * Creates a new {@link IIndicatorTextArea}.
	 *
	 * @return a new {@link IIndicatorTextArea}
	 *
	 * @since 1.4
	 */
	IIndicatorTextArea newIndicatorTextArea();

	/**
	 * Creates a new {@link IIndicatorTextArea}.
	 *
	 * @param text initial text to be set
	 * @return a new {@link IIndicatorTextArea}
	 *
	 * @since 1.4
	 */
	IIndicatorTextArea newIndicatorTextArea( String text );

	/**
	 * Creates a new {@link IBorderPanel}.
	 *
	 * @return a new {@link IBorderPanel}
	 */
	IBorderPanel newBorderPanel();

	/**
	 * Creates a new {@link IBorderPanel}.
	 *
	 * @param centerComp component to be added to the center
	 * @return a new {@link IBorderPanel}
	 */
	IBorderPanel newBorderPanel( JComponent centerComp );

	/**
	 * Creates a new {@link IBrowser}.
	 *
	 * @return a new {@link IBrowser}
	 */
	IBrowser newBrowser();

	/**
	 * Creates a new {@link IColorIcon}.
	 *
	 * @param color color of the icon.
	 * @return a new {@link IColorIcon}
	 */
	IColorIcon newColorIcon( Color color );

	/**
	 * Creates a new {@link IColorIcon}.
	 *
	 * @param color color of the icon.
	 * @param text text to be returned by the {@link IColorIcon#toString()} method
	 * @return a new {@link IColorIcon}
	 */
	IColorIcon newColorIcon( Color color, String text );

	/**
	 * Creates a new {@link IColorIcon}.
	 *
	 * @param color color of the icon.
	 * @param width width of the icon
	 * @param height height of the icon
	 * @return a new {@link IColorIcon}
	 */
	IColorIcon newColorIcon( Color color, int width, int height );

	/**
	 * Creates a new {@link IColorIcon}.
	 *
	 * @param color color of the icon.
	 * @param width width of the icon
	 * @param height height of the icon
	 * @param text text to be returned by the {@link IColorIcon#toString()} method
	 * @return a new {@link IColorIcon}
	 */
	IColorIcon newColorIcon( Color color, int width, int height, String text );

	/**
	 * Creates a new {@link IGridBagPanel}.
	 *
	 * @return a new {@link IGridBagPanel}
	 */
	IGridBagPanel newGridBagPanel();

	/**
	 * Creates a new {@link IModestLabel}.
	 *
	 * @return a new {@link IModestLabel}
	 */
	IModestLabel newModestLabel();

	/**
	 * Creates a new {@link IModestLabel}.
	 *
	 * @param text text of the label
	 * @return a new {@link IModestLabel}
	 */
	IModestLabel newModestLabel( String text );

	/**
	 * Creates a new {@link IFileChooser}.
	 *
	 * @return a new {@link IFileChooser}
	 */
	IFileChooser newFileChooser();

	/**
	 * Creates a new {@link IFileChooser}.
	 *
	 * @param currentFolder default folder to navigate to
	 * @return a new {@link IFileChooser}
	 */
	IFileChooser newFileChooser( Path currentFolder );

	/**
	 * Creates a new {@link IPathField} in folder mode.
	 *
	 * @return a new {@link IPathField}
	 */
	IPathField newPathField();

	/**
	 * Creates a new {@link IPathField} in the specified mode.
	 *
	 * @param fileMode if true, the field operates as a file chooser; else as a folder chooser
	 * @return a new {@link IPathField}
	 */
	IPathField newPathField( boolean fileMode );

	/**
	 * Creates a new {@link IPathField} in folder mode.
	 *
	 * @param path initial path to be set
	 * @return a new {@link IPathField}
	 */
	IPathField newPathField( Path path );

	/**
	 * Creates a new {@link IPathField} in the specified mode.
	 *
	 * @param path initial path to be set
	 * @param fileMode if true, the field operates as a file chooser; else as a folder chooser
	 * @return a new {@link IPathField}
	 */
	IPathField newPathField( Path path, boolean fileMode );

	/**
	 * Creates a new {@link IStatusLabel}.
	 *
	 * @return a new {@link IStatusLabel}
	 */
	IStatusLabel newStatusLabel();

	/**
	 * Creates a new {@link IStatusLabel}.
	 *
	 * @param type initial status type to be set
	 * @param message initial status message to be set
	 * @return a new {@link IStatusLabel}
	 */
	IStatusLabel newStatusLabel( IStatusType type, String message );

	/**
	 * Creates a new {@link ICheckBox}.
	 *
	 * @return a new {@link ICheckBox}
	 */
	ICheckBox newCheckBox();

	/**
	 * Creates a new {@link ICheckBox}.
	 *
	 * @param text text of the check box
	 * @return a new {@link ICheckBox}
	 */
	ICheckBox newCheckBox( String text );

	/**
	 * Creates a new {@link ICheckBox}.
	 *
	 * @param text text of the check box
	 * @param selected initial selected state
	 * @return a new {@link ICheckBox}
	 */
	ICheckBox newCheckBox( String text, boolean selected );

	/**
	 * Creates a new {@link IProgressBar}.
	 *
	 * @return a new {@link IProgressBar}
	 */
	IProgressBar newProgressBar();

	/**
	 * Creates a new {@link IScrollPane} with small preferred size.
	 *
	 * @return a new {@link IScrollPane}
	 */
	IScrollPane newScrollPane();

	/**
	 * Creates a new {@link IScrollPane} with small preferred size.
	 *
	 * @param view the component to be scrolled
	 * @return a new {@link IScrollPane}
	 */
	IScrollPane newScrollPane( Component view );

	/**
	 * Creates a new {@link IScrollPane}.
	 *
	 * @param view the component to be scrolled
	 * @param smallSize tells if small preferred size is to be set to prefer vertical scrolling instead of horizontal
	 * @return a new {@link IScrollPane}
	 */
	IScrollPane newScrollPane( Component view, boolean smallSize );

	/**
	 * Creates a new {@link IScrollPane}.
	 *
	 * @param view the component to be scrolled
	 * @param smallSize tells if small preferred size is to be set to prefer vertical scrolling instead of horizontal
	 * @param followScrollingSetting tells if the vertical scrolling amount setting is to be followed
	 * @return a new {@link IScrollPane}
	 */
	IScrollPane newScrollPane( Component view, boolean smallSize, boolean followScrollingSetting );

	/**
	 * Creates a new {@link ISpinner} with an {@link Integer} {@link SpinnerNumberModel} with initial value 0 and no minimum or maximum limits.
	 *
	 * @return a new {@link ISpinner}
	 */
	ISpinner newSpinner();

	/**
	 * Creates a new {@link ISpinner}.
	 *
	 * @param model model to create the spinner with
	 * @return a new {@link ISpinner}
	 */
	ISpinner newSpinner( SpinnerModel model );

	/**
	 * Creates a new {@link ISplitPane} using {@link JSplitPane#HORIZONTAL_SPLIT} orientation (the splitter will be vertical).
	 *
	 * @return a new {@link ISplitPane}
	 */
	ISplitPane newSplitPane();

	/**
	 * Creates a new {@link ISplitPane}.
	 *
	 * @param orientation orientation ({@link JSplitPane#HORIZONTAL_SPLIT} or {@link JSplitPane#VERTICAL_SPLIT})
	 * @return a new {@link ISplitPane}
	 */
	ISplitPane newSplitPane( int orientation );

	/**
	 * Creates a new {@link IToolBar}.
	 *
	 * @return a new {@link IToolBar}
	 */
	IToolBar newToolBar();

	/**
	 * Creates a new {@link IToolBar}.
	 *
	 * @param initialSpace tells if initial space component is to be added
	 * @return a new {@link IToolBar}
	 */
	IToolBar newToolBar( boolean initialSpace );

	/**
	 * Creates a new {@link IComboBox}.
	 *
	 * @param <E> type of the elements added to the combo box
	 * @return a new {@link IComboBox}
	 */
	< E > IComboBox< E > newComboBox();

	/**
	 * Creates a new {@link IComboBox}.
	 *
	 * @param <E> type of the elements added to the combo box
	 * @param items initial items to be added to the combo box
	 * @return a new {@link IComboBox}
	 */
	< E > IComboBox< E > newComboBox( E[] items );

	/**
	 * Creates a new {@link IComboBox}.
	 *
	 * @param <E> type of the elements added to the combo box
	 * @param items initial items to be added to the combo box
	 * @return a new {@link IComboBox}
	 */
	< E > IComboBox< E > newComboBox( Vector< E > items );

	/**
	 * Creates a new {@link ITable}.
	 *
	 * @return a new {@link ITable}
	 */
	ITable newTable();

	/**
	 * Creates a new {@link IProgressBarView} to be used in {@link ITable}s as a cell value.

	 * The string value will be the properly formatted value.
	 *
	 * @param value value for the progress bar
	 * @param maximum maximum value for the progress bar
	 * @return a new {@link IProgressBarView}
	 *
	 * @since 1.2
	 *
	 * @see #newProgressBarView(int, int, String)
	 * @see IProgressBarView
	 */
	IProgressBarView newProgressBarView( int value, int maximum );

	/**
	 * Creates a new {@link IProgressBarView} to be used in {@link ITable}s as a cell value.
	 *
	 * @param value value for the progress bar
	 * @param maximum maximum value for the progress bar
	 * @param stringValue string value to be displayed
	 * @return a new {@link IProgressBarView}
	 *
	 * @since 1.2
	 *
	 * @see #newProgressBarView(int, int)
	 * @see IProgressBarView
	 */
	IProgressBarView newProgressBarView( int value, int maximum, String stringValue );

	/**
	 * Creates a new {@link IBarCodeView} to be used in {@link ITable}s as a cell value.

	 * The string value will be the properly formatted value.
	 *
	 * @param values values of the parts of the bar code
	 * @param colors colors of the parts of the bar code
	 * @param selColors colors of the parts of the bar code when the cell is selected
	 * @return a new {@link IBarCodeView}
	 *
	 * @throws IllegalArgumentException if the number of values, colors and selected colors are not the same
	 *
	 * @since 1.2
	 *
	 * @see #newBarCodeView(int[], Color[], Color[], String)
	 * @see IBarCodeView
	 */
	IBarCodeView newBarCodeView( int[] values, Color[] colors, Color[] selColors );

	/**
	 * Creates a new {@link IBarCodeView} to be used in {@link ITable}s as a cell value.
	 *
	 * @param values values of the parts of the bar code
	 * @param colors colors of the parts of the bar code
	 * @param selColors colors of the parts of the bar code when the cell is selected
	 * @param stringValue string value to be displayed
	 * @return a new {@link IBarCodeView}
	 *
	 * @throws IllegalArgumentException if the number of values, colors and selected colors are not the same
	 *
	 * @since 1.2
	 *
	 * @see #newBarCodeView(int[], Color[], Color[])
	 * @see IBarCodeView
	 */
	IBarCodeView newBarCodeView( int[] values, Color[] colors, Color[] selColors, String stringValue );

	/**
	 * Creates a new {@link IToolBarForTable}.
	 *
	 * @param table targeted table whose selection changes to listen
	 * @return a new {@link IToolBarForTable}
	 */
	IToolBarForTable newToolBarForTable( ITable table );

	/**
	 * Creates a new {@link IList}.
	 *
	 * @param <E> type of the elements in the list
	 * @return a new {@link IList}
	 */
	< E > IList< E > newList();

	/**
	 * Creates a new {@link IToolBarForList}.
	 *
	 * @param list targeted list whose selection changes to listen
	 * @return a new {@link IToolBarForList}
	 */
	IToolBarForList newToolBarForList( IList< ? > list );

	/**
	 * Creates a new {@link ITree}.
	 *
	 * @param root root node
	 * @return a new {@link ITree}
	 */
	ITree newTree( TreeNode root );

	/**
	 * Creates a new {@link IToolBarForTree}.
	 *
	 * @param tree targeted tree whose selection changes to listen
	 * @return a new {@link IToolBarForTree}
	 */
	IToolBarForTree newToolBarForTree( ITree tree );

	/**
	 * Creates a new {@link IMenu}.
	 *
	 * @return a new {@link IMenu}
	 */
	IMenu newMenu();

	/**
	 * Creates a new {@link IMenu}.
	 *
	 * @param text text of the menu
	 * @return a new {@link IMenu}
	 */
	IMenu newMenu( String text );

	/**
	 * Creates a new {@link IMenu}.
	 *
	 * @param icon icon of the menu
	 * @return a new {@link IMenu}
	 */
	IMenu newMenu( Icon icon );

	/**
	 * Creates a new {@link IMenu}.
	 *
	 * @param text text of the menu
	 * @param icon icon of the menu
	 * @return a new {@link IMenu}
	 */
	IMenu newMenu( String text, Icon icon );

	/**
	 * Creates a new {@link IMenuItem}.
	 *
	 * @return a new {@link IMenuItem}
	 */
	IMenuItem newMenuItem();

	/**
	 * Creates a new {@link IMenuItem}.
	 *
	 * @param text text of the menu item
	 * @return a new {@link IMenuItem}
	 */
	IMenuItem newMenuItem( String text );

	/**
	 * Creates a new {@link IMenuItem}.
	 *
	 * @param icon icon of the menu item
	 * @return a new {@link IMenuItem}
	 */
	IMenuItem newMenuItem( Icon icon );

	/**
	 * Creates a new {@link IMenuItem}.
	 *
	 * @param text text of the menu item
	 * @param icon icon of the menu item
	 * @return a new {@link IMenuItem}
	 */
	IMenuItem newMenuItem( String text, Icon icon );

	/**
	 * Creates a new {@link ICheckBoxMenuItem}.
	 *
	 * @return a new {@link ICheckBoxMenuItem}
	 */
	ICheckBoxMenuItem newCheckBoxMenuItem();

	/**
	 * Creates a new {@link ICheckBoxMenuItem}.
	 *
	 * @param text text of the check box menu item
	 * @return a new {@link ICheckBoxMenuItem}
	 */
	ICheckBoxMenuItem newCheckBoxMenuItem( String text );

	/**
	 * Creates a new {@link ICheckBoxMenuItem}.
	 *
	 * @param icon icon of the check box menu item
	 * @return a new {@link ICheckBoxMenuItem}
	 */
	ICheckBoxMenuItem newCheckBoxMenuItem( Icon icon );

	/**
	 * Creates a new {@link ICheckBoxMenuItem}.
	 *
	 * @param text text of the check box menu item
	 * @param icon icon of the check box menu item
	 * @return a new {@link ICheckBoxMenuItem}
	 */
	ICheckBoxMenuItem newCheckBoxMenuItem( String text, Icon icon );

	/**
	 * Creates a new {@link IPasswordField}.
	 *
	 * @return a new {@link IPasswordField}
	 */
	IPasswordField newPasswordField();

	/**
	 * Creates a new {@link IPasswordField}.
	 *
	 * @param text initial text of the password field
	 * @return a new {@link IPasswordField}
	 */
	IPasswordField newPasswordField( String text );

	/**
	 * Creates a new {@link IPasswordField}.
	 *
	 * @param columns the number of columns to use to calculate the preferred width; if columns is set to zero, the preferred width will be whatever naturally
	 *            results from the component implementation
	 * @return a new {@link IPasswordField}
	 */
	IPasswordField newPasswordField( int columns );

	/**
	 * Creates a new {@link IPasswordField}.
	 *
	 * @param text initial text of the password field
	 * @param columns the number of columns to use to calculate the preferred width; if columns is set to zero, the preferred width will be whatever naturally
	 *            results from the component implementation
	 * @return a new {@link IPasswordField}
	 */
	IPasswordField newPasswordField( String text, int columns );

	/**
	 * Creates a new {@link IPopupMenu}.
	 *
	 * @return a new {@link IPopupMenu}
	 */
	IPopupMenu newPopupMenu();

	/**
	 * Creates a new {@link IPopupMenu}.
	 *
	 * @param text text of the popup title
	 * @return a new {@link IPopupMenu}
	 */
	IPopupMenu newPopupMenu( String text );

	/**
	 * Creates a new {@link IPopupMenu}.
	 *
	 * @param text text of the popup title
	 * @param icon icon of the popup title
	 * @return a new {@link IPopupMenu}
	 */
	IPopupMenu newPopupMenu( String text, Icon icon );

	/**
	 * Creates a new {@link IPopupMenu}.
	 *
	 * @param titleLabel title label of the popup
	 * @return a new {@link IPopupMenu}
	 */
	IPopupMenu newPopupMenu( ILabel titleLabel );

	/**
	 * Creates a new {@link ITabbedPane}.
	 *
	 * @return a new {@link ITabbedPane}
	 */
	ITabbedPane newTabbedPane();

	/**
	 * Creates a new {@link IPage}.
	 *
	 * @param <T> type of the page component
	 * @param displayName display name of the page
	 * @param ricon ricon of the page
	 * @param closeable tells if the page is closeable
	 * @param pageCompCreator page component creator
	 * @return a new {@link IPage}
	 *
	 * @see IPage
	 * @see IPageCompCreator
	 */
	< T extends JComponent > IPage< T > newPage( String displayName, IRIcon ricon, boolean closeable, IPageCompCreator< T > pageCompCreator );

	/**
	 * Creates a new {@link IPage} which creates {@link IBrowser} as page component to display the specified HTML resource.
	 *
	 * @param displayName display name of the page
	 * @param ricon icon resource of the page
	 * @param rhtml HTML template resource to display as content
	 * @return a new {@link IPage}
	 */
	IPage< ? extends IBrowser > newBrowserPage( String displayName, IRIcon ricon, IRHtml rhtml );

	/**
	 * Creates a new {@link IMultiPageComp}.
	 *
	 * @param pageList initial page list to be set
	 * @param defaultPage optional page to select by default; if null, the first page will be selected
	 * @param rootComponent root component to register key strokes at
	 * @return a new {@link IMultiPageComp}
	 *
	 * @see IMultiPageComp
	 * @see #newPage(String, IRIcon, boolean, IPageCompCreator)
	 */
	IMultiPageComp newMultiPageComp( List< IPage< ? > > pageList, IPage< ? > defaultPage, JComponent rootComponent );

	/**
	 * Creates a new {@link ITemplateField} with a template editor dialog opener button added.
	 *
	 * @return a new {@link ITemplateField}
	 */
	ITemplateField newTemplateField();

	/**
	 * Creates a new {@link ITemplateField} with a template editor dialog opener button added.
	 *
	 * @param template initial template to be set
	 * @return a new {@link ITemplateField}
	 */
	ITemplateField newTemplateField( String template );

	/**
	 * Creates a new {@link ITemplateField}.
	 *
	 * @param addDialogOpener tells if a template editor dialog opener button is to be added
	 * @return a new {@link ITemplateField}
	 */
	ITemplateField newTemplateField( boolean addDialogOpener );

	/**
	 * Creates a new {@link ITemplateField}.
	 *
	 * @param template initial template to be set
	 * @param addDialogOpener tells if a template editor dialog opener button is to be added
	 * @return a new {@link ITemplateField}
	 */
	ITemplateField newTemplateField( String template, boolean addDialogOpener );

	/**
	 * Creates a new {@link IDialog} whose parent will be the main frame ({@link IServices#getMainFrame()}).
	 *
	 *

	 * The returned dialog is not yet made visible.
	 *

	 *
	 * @param closeTask optional close task to be run right before the dialog is closed
	 * @return a new {@link IDialog}
	 *
	 * @see IDialog
	 */
	IDialog newDialog( Runnable closeTask );

	/**
	 * Creates a new {@link IDialog} with the specified parent frame.
	 *
	 *

	 * The returned dialog is not yet made visible.
	 *

	 *
	 * @param owner reference to the owner frame
	 * @param closeTask optional close task to be run right before the dialog is closed
	 * @return a new {@link IDialog}
	 *
	 * @see IDialog
	 */
	IDialog newDialog( Frame owner, Runnable closeTask );

	/**
	 * Creates a new {@link IDialog} with the specified parent frame.
	 *
	 *

	 * The returned overlay card is not yet made visible.
	 *

	 *
	 * @param params overlay card parameters wrapper
	 * @param configPopupBuilder optional config popup builder, can be used to add custom items to the config popup (before it is displayed)
	 * @param closeTask optional close task to be run right before the overlay card is closed
	 * @return a new {@link IDialog}
	 *
	 * @see IDialog
	 * @see OverlayCardParams
	 * @see IConfigPopupBuilder
	 */
	IOverlayCard newOverlayCard( OverlayCardParams params, IConfigPopupBuilder configPopupBuilder, Runnable closeTask );

	/**
	 * Creates a new IMMUTABLE {@link IRenderablePair}.
	 *
	 * @param <T> type of the object providing the displayed text
	 * @param icon icon to be rendered
	 * @param textProvider object providing the displayable text (acquired by {@link Object#toString()})
	 * @return a new {@link IRenderablePair}
	 *
	 * @see IRenderablePair
	 */
	< T > IRenderablePair< T > newRenderablePair( Icon icon, T textProvider );

}


text:
function theResult = doload(self, theFilename)

% seagrid/doload -- Load a grid.
%  doload(self, 'theFilename') loads the grid and other
%   information associated with self, a "seagrid" object,
%   from 'theFilename'.  The "uigetfile" dialog is invoked
%   if an empty or wildcarded name is provided.

% svn $Id: doload.m 328 2009-03-09 01:41:19Z arango $
%=======================================================================
% Copyright (C) 1999 Dr. Charles R. Denham, ZYDECO.
%  All Rights Reserved.
%   Disclosure without explicit written consent from the
%    copyright owner does not constitute publication.
%=======================================================================

% Version of 13-May-1999 15:58:14.
% Updated    10-Jul-2000 10:07:06.

if nargout > 0, theResult = []; end
if nargin < 1, help(mfilename), return, end
if nargin < 2, theFilename = ''; end

if nargout > 0, theResult = self; end

if isempty(theFilename), theFilename = '*.mat'; end

if any(theFilename == '*')
	[theFile, thePath] = uigetfile(theFilename, 'Select SeaGrid File:');
	if ~any(theFile), return, end
	if thePath(end) ~= filesep, thePath(end+1) = filesep; end
	theFilename = [thePath theFile];
end

loaded = load(theFilename);
if ~isfield(loaded, 's'), return, end

theMaskToolFlag = psget(self, 'itsMaskToolFlag');
theMaskTool = psget(self, 'itsMaskTool');
if any(theMaskTool)
	domasktool(self)   % Turn it off.
end

s = loaded.s;

psset(self, 'itsSeaGridOutputFile', theFilename)
psset(self, 'itsProjection', s.projection)
psset(self, 'itsProjectionCenter', s.projection_center)
psset(self, 'itsLongitudeBounds', s.longitude_bounds)
psset(self, 'itsLatitudeBounds', s.latitude_bounds)
psset(self, 'itsCoastlineFile', s.coastline)
psset(self, 'itsBathymetryFile', s.bathymetry)
psset(self, 'itsPoints', s.points)
psset(self, 'itsEndSlopeFlag', s.end_slope_flag)
psset(self, 'itsGridSize', s.grid_size)
psset(self, 'itsGrids', s.grids)
psset(self, 'itsSpacings', s.spacings)
psset(self, 'itsDefaultSpacings', s.default_spacings)
psset(self, 'itsSpacedEdges', s.spaced_edges)
psset(self, 'itsSpacedGrids', s.spaced_grids)
psset(self, 'itsGriddedBathymetry', -s.gridded_bathymetry)
psset(self, 'itsClippingDepths', s.clipping_depths)
psset(self, 'itsMask', s.mask)
psset(self, 'itsWater', s.water)
psset(self, 'itsLand', s.land)

sg_proj(s.projection)

if (0), psset(self, 'itsGridSize', s.grid_size/2), end   % No longer.

getboundary(self, 'clear')

% dogrid(self, 1)

% If alive, the masktool will be turned back on during update.

doupdate(self, 1)

getcoastline(self)
getbathymetry(self)

if nargout > 0, theResult = self; end


text:
require 'seahorse/client/plugins/content_length.rb'
require 'aws-sdk-core/plugins/credentials_configuration.rb'
require 'aws-sdk-core/plugins/logging.rb'
require 'aws-sdk-core/plugins/param_converter.rb'
require 'aws-sdk-core/plugins/param_validator.rb'
require 'aws-sdk-core/plugins/user_agent.rb'
require 'aws-sdk-core/plugins/helpful_socket_errors.rb'
require 'aws-sdk-core/plugins/retry_errors.rb'
require 'aws-sdk-core/plugins/global_configuration.rb'
require 'aws-sdk-core/plugins/regional_endpoint.rb'
require 'aws-sdk-core/plugins/response_paging.rb'
require 'aws-sdk-core/plugins/stub_responses.rb'
require 'aws-sdk-core/plugins/idempotency_token.rb'
require 'aws-sdk-core/plugins/jsonvalue_converter.rb'
require 'aws-sdk-core/plugins/signature_v4.rb'
require 'aws-sdk-core/plugins/protocols/json_rpc.rb'

Aws::Plugins::GlobalConfiguration.add_identifier(:resourcegroupstaggingapi)

module Aws::ResourceGroupsTaggingAPI
  class Client < Seahorse::Client::Base

    include Aws::ClientStubs

    @identifier = :resourcegroupstaggingapi

    set_api(ClientApi::API)

    add_plugin(Seahorse::Client::Plugins::ContentLength)
    add_plugin(Aws::Plugins::CredentialsConfiguration)
    add_plugin(Aws::Plugins::Logging)
    add_plugin(Aws::Plugins::ParamConverter)
    add_plugin(Aws::Plugins::ParamValidator)
    add_plugin(Aws::Plugins::UserAgent)
    add_plugin(Aws::Plugins::HelpfulSocketErrors)
    add_plugin(Aws::Plugins::RetryErrors)
    add_plugin(Aws::Plugins::GlobalConfiguration)
    add_plugin(Aws::Plugins::RegionalEndpoint)
    add_plugin(Aws::Plugins::ResponsePaging)
    add_plugin(Aws::Plugins::StubResponses)
    add_plugin(Aws::Plugins::IdempotencyToken)
    add_plugin(Aws::Plugins::JsonvalueConverter)
    add_plugin(Aws::Plugins::SignatureV4)
    add_plugin(Aws::Plugins::Protocols::JsonRpc)

    # @option options [required, Aws::CredentialProvider] :credentials
    #   Your AWS credentials. This can be an instance of any one of the
    #   following classes:
    #
    #   * `Aws::Credentials` - Used for configuring static, non-refreshing
    #     credentials.
    #
    #   * `Aws::InstanceProfileCredentials` - Used for loading credentials
    #     from an EC2 IMDS on an EC2 instance.
    #
    #   * `Aws::SharedCredentials` - Used for loading credentials from a
    #     shared file, such as `~/.aws/config`.
    #
    #   * `Aws::AssumeRoleCredentials` - Used when you need to assume a role.
    #
    #   When `:credentials` are not configured directly, the following
    #   locations will be searched for credentials:
    #
    #   * `Aws.config[:credentials]`
    #   * The `:access_key_id`, `:secret_access_key`, and `:session_token` options.
    #   * ENV['AWS_ACCESS_KEY_ID'], ENV['AWS_SECRET_ACCESS_KEY']
    #   * `~/.aws/credentials`
    #   * `~/.aws/config`
    #   * EC2 IMDS instance profile - When used by default, the timeouts are
    #     very aggressive. Construct and pass an instance of
    #     `Aws::InstanceProfileCredentails` to enable retries and extended
    #     timeouts.
    #
    # @option options [required, String] :region
    #   The AWS region to connect to.  The configured `:region` is
    #   used to determine the service `:endpoint`. When not passed,
    #   a default `:region` is search for in the following locations:
    #
    #   * `Aws.config[:region]`
    #   * `ENV['AWS_REGION']`
    #   * `ENV['AMAZON_REGION']`
    #   * `ENV['AWS_DEFAULT_REGION']`
    #   * `~/.aws/credentials`
    #   * `~/.aws/config`
    #
    # @option options [String] :access_key_id
    #
    # @option options [Boolean] :convert_params (true)
    #   When `true`, an attempt is made to coerce request parameters into
    #   the required types.
    #
    # @option options [String] :endpoint
    #   The client endpoint is normally constructed from the `:region`
    #   option. You should only configure an `:endpoint` when connecting
    #   to test endpoints. This should be avalid HTTP(S) URI.
    #
    # @option options [Aws::Log::Formatter] :log_formatter (Aws::Log::Formatter.default)
    #   The log formatter.
    #
    # @option options [Symbol] :log_level (:info)
    #   The log level to send messages to the `:logger` at.
    #
    # @option options [Logger] :logger
    #   The Logger instance to send log messages to.  If this option
    #   is not set, logging will be disabled.
    #
    # @option options [String] :profile ("default")
    #   Used when loading credentials from the shared credentials file
    #   at HOME/.aws/credentials.  When not specified, 'default' is used.
    #
    # @option options [Float] :retry_base_delay (0.3)
    #   The base delay in seconds used by the default backoff function.
    #
    # @option options [Symbol] :retry_jitter (:none)
    #   A delay randomiser function used by the default backoff function. Some predefined functions can be referenced by name - :none, :equal, :full, otherwise a Proc that takes and returns a number.
    #
    #   @see https://www.awsarchitectureblog.com/2015/03/backoff.html
    #
    # @option options [Integer] :retry_limit (3)
    #   The maximum number of times to retry failed requests.  Only
    #   ~ 500 level server errors and certain ~ 400 level client errors
    #   are retried.  Generally, these are throttling errors, data
    #   checksum errors, networking errors, timeout errors and auth
    #   errors from expired credentials.
    #
    # @option options [Integer] :retry_max_delay (0)
    #   The maximum number of seconds to delay between retries (0 for no limit) used by the default backoff function.
    #
    # @option options [String] :secret_access_key
    #
    # @option options [String] :session_token
    #
    # @option options [Boolean] :simple_json (false)
    #   Disables request parameter conversion, validation, and formatting.
    #   Also disable response data type conversions. This option is useful
    #   when you want to ensure the highest level of performance by
    #   avoiding overhead of walking request parameters and response data
    #   structures.
    #
    #   When `:simple_json` is enabled, the request parameters hash must
    #   be formatted exactly as the DynamoDB API expects.
    #
    # @option options [Boolean] :stub_responses (false)
    #   Causes the client to return stubbed responses. By default
    #   fake responses are generated and returned. You can specify
    #   the response data to return or errors to raise by calling
    #   {ClientStubs#stub_responses}. See {ClientStubs} for more information.
    #
    #   ** Please note ** When response stubbing is enabled, no HTTP
    #   requests are made, and retries are disabled.
    #
    # @option options [Boolean] :validate_params (true)
    #   When `true`, request parameters are validated before
    #   sending the request.
    #
    def initialize(*args)
      super
    end

    # @!group API Operations

    # Returns all the tagged resources that are associated with the
    # specified tags (keys and values) located in the specified region for
    # the AWS account. The tags and the resource types that you specify in
    # the request are known as *filters*. The response includes all tags
    # that are associated with the requested resources. If no filter is
    # provided, this action returns a paginated resource list with the
    # associated tags.
    #
    # @option params [String] :pagination_token
    #   A string that indicates that additional data is available. Leave this
    #   value empty for your initial request. If the response includes a
    #   `PaginationToken`, use that string for this value to request an
    #   additional page of data.
    #
    # @option params [Array<Types::TagFilter>] :tag_filters
    #   A list of tags (keys and values). A request can include up to 50 keys,
    #   and each key can include up to 20 values.
    #
    #   If you specify multiple filters connected by an AND operator in a
    #   single request, the response returns only those resources that are
    #   associated with every specified filter.
    #
    #   If you specify multiple filters connected by an OR operator in a
    #   single request, the response returns all resources that are associated
    #   with at least one or possibly more of the specified filters.
    #
    # @option params [Integer] :resources_per_page
    #   A limit that restricts the number of resources returned by
    #   GetResources in paginated output. You can set ResourcesPerPage to a
    #   minimum of 1 item and the maximum of 50 items.
    #
    # @option params [Integer] :tags_per_page
    #   A limit that restricts the number of tags (key and value pairs)
    #   returned by GetResources in paginated output. A resource with no tags
    #   is counted as having one tag (one key and value pair).
    #
    #   `GetResources` does not split a resource and its associated tags
    #   across pages. If the specified `TagsPerPage` would cause such a break,
    #   a `PaginationToken` is returned in place of the affected resource and
    #   its tags. Use that token in another request to get the remaining data.
    #   For example, if you specify a `TagsPerPage` of `100` and the account
    #   has 22 resources with 10 tags each (meaning that each resource has 10
    #   key and value pairs), the output will consist of 3 pages, with the
    #   first page displaying the first 10 resources, each with its 10 tags,
    #   the second page displaying the next 10 resources each with its 10
    #   tags, and the third page displaying the remaining 2 resources, each
    #   with its 10 tags.
    #
    #
    #
    #   You can set `TagsPerPage` to a minimum of 100 items and the maximum of
    #   500 items.
    #
    # @option params [Array<String>] :resource_type_filters
    #   The constraints on the resources that you want returned. The format of
    #   each resource type is `service[:resourceType]`. For example,
    #   specifying a resource type of `ec2` returns all tagged Amazon EC2
    #   resources (which includes tagged EC2 instances). Specifying a resource
    #   type of `ec2:instance` returns only EC2 instances.
    #
    #   The string for each service name and resource type is the same as that
    #   embedded in a resource's Amazon Resource Name (ARN). Consult the *AWS
    #   General Reference* for the following:
    #
    #   * For a list of service name strings, see [AWS Service Namespaces][1].
    #
    #   * For resource type strings, see [Example ARNs][2].
    #
    #   * For more information about ARNs, see [Amazon Resource Names (ARNs)
    #     and AWS Service Namespaces][3].
    #
    #
    #
    #   [1]: http://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html#genref-aws-service-namespaces
    #   [2]: http://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html#arns-syntax
    #   [3]: http://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html
    #
    # @return [Types::GetResourcesOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
    #
    #   * {Types::GetResourcesOutput#pagination_token #pagination_token} => String
    #   * {Types::GetResourcesOutput#resource_tag_mapping_list #resource_tag_mapping_list} => Array<Types::ResourceTagMapping>
    #
    # @example Request syntax with placeholder values
    #
    #   resp = client.get_resources({
    #     pagination_token: "PaginationToken",
    #     tag_filters: [
    #       {
    #         key: "TagKey",
    #         values: ["TagValue"],
    #       },
    #     ],
    #     resources_per_page: 1,
    #     tags_per_page: 1,
    #     resource_type_filters: ["AmazonResourceType"],
    #   })
    #
    # @example Response structure
    #
    #   resp.pagination_token #=> String
    #   resp.resource_tag_mapping_list #=> Array
    #   resp.resource_tag_mapping_list[0].resource_arn #=> String
    #   resp.resource_tag_mapping_list[0].tags #=> Array
    #   resp.resource_tag_mapping_list[0].tags[0].key #=> String
    #   resp.resource_tag_mapping_list[0].tags[0].value #=> String
    #
    # @see http://docs.aws.amazon.com/goto/WebAPI/resourcegroupstaggingapi-2017-01-26/GetResources AWS API Documentation
    #
    # @overload get_resources(params = {})
    # @param [Hash] params ({})
    def get_resources(params = {}, options = {})
      req = build_request(:get_resources, params)
      req.send_request(options)
    end

    # Returns all tag keys in the specified region for the AWS account.
    #
    # @option params [String] :pagination_token
    #   A string that indicates that additional data is available. Leave this
    #   value empty for your initial request. If the response includes a
    #   PaginationToken, use that string for this value to request an
    #   additional page of data.
    #
    # @return [Types::GetTagKeysOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
    #
    #   * {Types::GetTagKeysOutput#pagination_token #pagination_token} => String
    #   * {Types::GetTagKeysOutput#tag_keys #tag_keys} => Array<String>
    #
    # @example Request syntax with placeholder values
    #
    #   resp = client.get_tag_keys({
    #     pagination_token: "PaginationToken",
    #   })
    #
    # @example Response structure
    #
    #   resp.pagination_token #=> String
    #   resp.tag_keys #=> Array
    #   resp.tag_keys[0] #=> String
    #
    # @see http://docs.aws.amazon.com/goto/WebAPI/resourcegroupstaggingapi-2017-01-26/GetTagKeys AWS API Documentation
    #
    # @overload get_tag_keys(params = {})
    # @param [Hash] params ({})
    def get_tag_keys(params = {}, options = {})
      req = build_request(:get_tag_keys, params)
      req.send_request(options)
    end

    # Returns all tag values for the specified key in the specified region
    # for the AWS account.
    #
    # @option params [String] :pagination_token
    #   A string that indicates that additional data is available. Leave this
    #   value empty for your initial request. If the response includes a
    #   PaginationToken, use that string for this value to request an
    #   additional page of data.
    #
    # @option params [required, String] :key
    #   The key for which you want to list all existing values in the
    #   specified region for the AWS account.
    #
    # @return [Types::GetTagValuesOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
    #
    #   * {Types::GetTagValuesOutput#pagination_token #pagination_token} => String
    #   * {Types::GetTagValuesOutput#tag_values #tag_values} => Array<String>
    #
    # @example Request syntax with placeholder values
    #
    #   resp = client.get_tag_values({
    #     pagination_token: "PaginationToken",
    #     key: "TagKey", # required
    #   })
    #
    # @example Response structure
    #
    #   resp.pagination_token #=> String
    #   resp.tag_values #=> Array
    #   resp.tag_values[0] #=> String
    #
    # @see http://docs.aws.amazon.com/goto/WebAPI/resourcegroupstaggingapi-2017-01-26/GetTagValues AWS API Documentation
    #
    # @overload get_tag_values(params = {})
    # @param [Hash] params ({})
    def get_tag_values(params = {}, options = {})
      req = build_request(:get_tag_values, params)
      req.send_request(options)
    end

    # Applies one or more tags to the specified resources. Note the
    # following:
    #
    # * Not all resources can have tags. For a list of resources that
    #   support tagging, see [Supported Resources][1] in the *AWS Resource
    #   Groups and Tag Editor User Guide*.
    #
    # * Each resource can have up to 50 tags. For other limits, see [Tag
    #   Restrictions][2] in the *Amazon EC2 User Guide for Linux Instances*.
    #
    # * You can only tag resources that are located in the specified region
    #   for the AWS account.
    #
    # * To add tags to a resource, you need the necessary permissions for
    #   the service that the resource belongs to as well as permissions for
    #   adding tags. For more information, see [Obtaining Permissions for
    #   Tagging][3] in the *AWS Resource Groups and Tag Editor User Guide*.
    #
    #
    #
    # [1]: http://docs.aws.amazon.com/awsconsolehelpdocs/latest/gsg/supported-resources.html
    # [2]: http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Using_Tags.html#tag-restrictions
    # [3]: http://docs.aws.amazon.com/awsconsolehelpdocs/latest/gsg/obtaining-permissions-for-tagging.html
    #
    # @option params [required, Array<String>] :resource_arn_list
    #   A list of ARNs. An ARN (Amazon Resource Name) uniquely identifies a
    #   resource. You can specify a minimum of 1 and a maximum of 20 ARNs
    #   (resources) to tag. An ARN can be set to a maximum of 1600 characters.
    #   For more information, see [Amazon Resource Names (ARNs) and AWS
    #   Service Namespaces][1] in the *AWS General Reference*.
    #
    #
    #
    #   [1]: http://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html
    #
    # @option params [required, Hash<String,String>] :tags
    #   The tags that you want to add to the specified resources. A tag
    #   consists of a key and a value that you define.
    #
    # @return [Types::TagResourcesOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
    #
    #   * {Types::TagResourcesOutput#failed_resources_map #failed_resources_map} => Hash<String,Types::FailureInfo>
    #
    # @example Request syntax with placeholder values
    #
    #   resp = client.tag_resources({
    #     resource_arn_list: ["ResourceARN"], # required
    #     tags: { # required
    #       "TagKey" => "TagValue",
    #     },
    #   })
    #
    # @example Response structure
    #
    #   resp.failed_resources_map #=> Hash
    #   resp.failed_resources_map["ResourceARN"].status_code #=> Integer
    #   resp.failed_resources_map["ResourceARN"].error_code #=> String, one of "InternalServiceException", "InvalidParameterException"
    #   resp.failed_resources_map["ResourceARN"].error_message #=> String
    #
    # @see http://docs.aws.amazon.com/goto/WebAPI/resourcegroupstaggingapi-2017-01-26/TagResources AWS API Documentation
    #
    # @overload tag_resources(params = {})
    # @param [Hash] params ({})
    def tag_resources(params = {}, options = {})
      req = build_request(:tag_resources, params)
      req.send_request(options)
    end

    # Removes the specified tags from the specified resources. When you
    # specify a tag key, the action removes both that key and its associated
    # value. The operation succeeds even if you attempt to remove tags from
    # a resource that were already removed. Note the following:
    #
    # * To remove tags from a resource, you need the necessary permissions
    #   for the service that the resource belongs to as well as permissions
    #   for removing tags. For more information, see [Obtaining Permissions
    #   for Tagging][1] in the *AWS Resource Groups and Tag Editor User
    #   Guide*.
    #
    # * You can only tag resources that are located in the specified region
    #   for the AWS account.
    #
    #
    #
    # [1]: http://docs.aws.amazon.com/awsconsolehelpdocs/latest/gsg/obtaining-permissions-for-tagging.html
    #
    # @option params [required, Array<String>] :resource_arn_list
    #   A list of ARNs. An ARN (Amazon Resource Name) uniquely identifies a
    #   resource. You can specify a minimum of 1 and a maximum of 20 ARNs
    #   (resources) to untag. An ARN can be set to a maximum of 1600
    #   characters. For more information, see [Amazon Resource Names (ARNs)
    #   and AWS Service Namespaces][1] in the *AWS General Reference*.
    #
    #
    #
    #   [1]: http://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html
    #
    # @option params [required, Array<String>] :tag_keys
    #   A list of the tag keys that you want to remove from the specified
    #   resources.
    #
    # @return [Types::UntagResourcesOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
    #
    #   * {Types::UntagResourcesOutput#failed_resources_map #failed_resources_map} => Hash<String,Types::FailureInfo>
    #
    # @example Request syntax with placeholder values
    #
    #   resp = client.untag_resources({
    #     resource_arn_list: ["ResourceARN"], # required
    #     tag_keys: ["TagKey"], # required
    #   })
    #
    # @example Response structure
    #
    #   resp.failed_resources_map #=> Hash
    #   resp.failed_resources_map["ResourceARN"].status_code #=> Integer
    #   resp.failed_resources_map["ResourceARN"].error_code #=> String, one of "InternalServiceException", "InvalidParameterException"
    #   resp.failed_resources_map["ResourceARN"].error_message #=> String
    #
    # @see http://docs.aws.amazon.com/goto/WebAPI/resourcegroupstaggingapi-2017-01-26/UntagResources AWS API Documentation
    #
    # @overload untag_resources(params = {})
    # @param [Hash] params ({})
    def untag_resources(params = {}, options = {})
      req = build_request(:untag_resources, params)
      req.send_request(options)
    end

    # @!endgroup

    # @param params ({})
    # @api private
    def build_request(operation_name, params = {})
      handlers = @handlers.for(operation_name)
      context = Seahorse::Client::RequestContext.new(
        operation_name: operation_name,
        operation: config.api.operation(operation_name),
        client: self,
        params: params,
        config: config)
      context[:gem_name] = 'aws-sdk-resourcegroupstaggingapi'
      context[:gem_version] = '1.1.0'
      Seahorse::Client::Request.new(handlers, context)
    end

    # @api private
    # @deprecated
    def waiter_names
      []
    end

    class << self

      # @api private
      attr_reader :identifier

      # @api private
      def errors_module
        Errors
      end

    end
  end
end


text:
package leakybucket

import (
	"testing"
)

// START OMIT
func TestCreate(t *testing.T) {
	CreateTest(New())(t)
}

// END OMIT


text:
json_value *access_json_hash(const json_value *p, const json_char *key);
bool assertinteger(const char *varname, const json_value *val);
bool try_assign_integer_variable(unsigned short *out, const char *varname, const char *key, const json_value *val);
bool try_assign_double_variable(double *out, const char *varname, const char *key, const json_value *val);
bool try_assign_float_variable(float *out, const char *varname, const char *key, const json_value *val);
char *json_string_to_cstring(const json_value *val);
bool json_check_magic(const json_value *p, const char *type_name);

json_value *json_parse_file(const char *path, const char *type_name = 0);
bool json_assign_double(double *out, const json_value *val);
bool json_assign_float(float *out, const json_value *val);
#endif


text:
Simple MongoDB wrapper. Will present a consistent promised API for both MongoDB and NEDB databases.

This will be incredibly useful for testing using local files rather than actual MongoDB instances. This will also be very useful for using a MongoDB-like database for work that can use simple flat files. In this case your fixtures can just be the NEDB files, which are an extended form of JSON.

## Installation
```
npm install --save access-mongo
```

## Usage

```javascript
var AccessMongo = require('access-mongo');

AccessMongo.connect('mongodb://foo:bar@hello.com:1234/mydb').then(function() {
  // create a model for collection users
  var User = AccessMongo.createModel('users');

  User.where({name: 'Matt'}).then(function(user) {
    console.log(user);
  });
});

// connect to multiple databases
AccessMongo.connect({
  foo: 'mongodb://foo:bar@hello.com:1234/mydb',
  bar: 'mongodb://foo:bar@yoyo.foo.bar:1234/otherdb'
}).then(function() {
  var FooUser = AccessMongo.createModel('users', {connection: 'foo'});
  var BarUser = AccessMongo.createModel('users', {connection: 'foo'});
});

// override query parameters of all connections
AccessMongo.connect({
  foo: 'mongodb://foo:bar@hello.com:1234/mydb',
  bar: 'mongodb://foo:bar@yoyo.foo.bar:1234/otherdb'
}, {
  maxPoolSize: 3
});

// create an nedb database
AccessMongo.connect('test.db').then(function() {
  var User = AccessMongo.createModel('users');

  User.where({name: 'Matt'}).then(function(user) {
    console.log(user);
  });
});

```

## Primary API

### AccessMongo

`AccessMongo` is a singleton that manages the connection state to each database you connect to. You can connect to one or multiple databases. Each connection has a name that you can use to refer to it later. If you don't specify a name the connection name will be `default`.

#### Connecting to a single database

Returns a promise that resolves to the instance of `AccessMongo`.

```javascript
AccessMongo.connect('mongodb://localhost:27017/test-db');
```

#### Connecting to a multiple databases

Returns a promise that resolves to the instance of `AccessMongo`.

```javascript
AccessMongo.connect({
  default: 'mongodb://localhost:27017/test-db',
  foo: 'mongodb://foo:bar@other.db.com:27019/some-db'
});
```

#### Disconnecting from all databases

Returns a promise that resolves to the instance of `AccessMongo`.

```javascript
AccessMongo.disconnect();
```

#### Creating a model

Returns a `Model` object.

```javascript
// create a model stored in the 'users' collection
var User = AccessMongo.createModel('users');

// create a model stored in the 'users' collection, 'foo' connection, default database
var User = AccessMongo.createModel('users', {connection: 'foo'});

// create a model stored in the 'users' collection, 'default' connection, 'other-db' database
var User = AccessMongo.createModel('users', {database: 'other-db'});

// create a model stored in the 'users' collection, 'foo' connection, 'other-db' database
var User = AccessMongo.createModel('users', {connection: 'foo', database: 'other-db'});
```

### Model

#### Creating a query

```javascript
// create a query
var query = User.where({name: 'Matt Insler'});

// add to a query
query.where({email: 'matt.insler@gmail.com'});
```

#### Modifying a query

```javascript
// skip
User.skip(5);
User.where({...}).skip(5);

// limit

// fields
User.fields({name: 1, address});        // only include name and address
User.where({...}).fields({timestamp: 0}); // omit timestamp

// sort
User.sort({name: 1});             // sort by name ascending
User.where({...}).sort({name: -1}); // sort by name descending
```

#### Fetching data from a query

```javascript
// fetch the first document matching this query
User.first().then(function(user) {

});
User.where({...}).then(function(user) {

});

// fetch all documents matching this query
User.array().then(function(users) {

});
User.where({...}).array().then(function(users) {

});

// Create a cursor for this query
var cursor = User.cursor();
var cursor = User.where({...}).cursor();

// Count the documents matching this query
User.count().then(function(count) {

});
User.where({...}).count().then(function(count) {

});

// Get a list of distinct values of the field matching this query
User.distinct('name').then(function(distinctNames) {

});
User.where({...}).distinct('name').then(function(distinctNames) {

});
```

### Inserting/updating documents

```javascript
// Insert a document, will not update
User.create({...}).then(function(savedDocument) {

);
// Insert multiple documents, will not update
User.create([{...}, {...}]).then(function(arrayOfSavedDocuments) {

);

// Save a document, doing an update if the document has an '_id' field, and an insert if not
User.save({...}).then(function(savedDocument) {

});

// Update a single document matching the query
// options: http://mongodb.github.io/node-mongodb-native/1.4/api-generated/collection.html#update
User.update(query, update, options).then(function(numDocumentsChanged, details) {
  // check details.updatedExisting to see if objects were inserted or updated (when using {upsert: true})
});
// Update a single document matching the query from the where({...})
User.where({...}).update(update, options).then(function(numDocumentsChanged, details) {

});

User.where({...}).firstAndUpdate(update, options).then(function(fetchedDocument) {

});
```

### Removing documents

```javascript
// To prevent you from removing all documents by accident, this will throw an Error
User.remove();

// To remove all documents you can override this failsafe
User.remove({ override: true });

// Remove all documents matching this query
User.where({...}).remove().then(function(numDocumentsRemoved) {

});
```

## Lower-level API

### AccessMongo

#### Get the default connection

Returns the default connection object if there is a one or `null`.

This is the equivalent of `AccessMongo.getConnection('default')`.

```javascript
var connection = AccessMongo.getDefaultConnection();
```

#### Get a connection by name

Returns the connection object by name or `null`.

```javascript
var connection = AccessMongo.getConnection('foo');
```

### Connection

#### Get the default database

```javascript
var db = connection.getDefaultConnection();
```

#### Get a database by name

```javascript
var db = connection.getDatabase('my-db');
```

#### Disconnect this connection

```javascript
connection.disconnect();
```

### Database

#### Get a collection from the database

```javascript
var collection = db.getCollection('users');
```

## License
Copyright (c) 2015 Matt Insler
Licensed under the MIT license.


text:
{% extends "base.html" %}
{% load static %}

{% block title %}Sign in ‹ {{ block.super }}{% endblock %}

{% block body_attr %} data-active-nav-id="signin"{% endblock %}

{% block body %}

Sign in

In order to sign in, you'll need an Google Account. If you do not have an Google Account yet, you can create one here.

                <form class="uk-form" method="post" action="{% url 'my:auth' %}">
                    {% csrf_token %}
                    <input type="image" src="{% static 'img/gplus-signin-1x.png' %}">
                </form>

{% endblock %}


text:
module.exports = function(config) {
  config.set({

    // base path that will be used to resolve all patterns (eg. files, exclude)
    basePath: '',

    // frameworks to use
    // available frameworks: https://npmjs.org/browse/keyword/karma-adapter
    frameworks: ['mocha', 'browserify'],

    // list of files / patterns to load in the browser
    files: [
      //'test/test.*.js'
      //'test/test.wrapper.js' // works
      'test/test.alchemy_data_news.v1.js'
    ],

    // list of files to exclude
    exclude: [
    ],

    // preprocess matching files before serving them to the browser
    // available preprocessors: https://npmjs.org/browse/keyword/karma-preprocessor
    preprocessors: {
      'test/test.*.js': ['browserify']
    },

    browserify: {
      debug: true,
      // transform is for browserify plugins:
      // 'brfs' makes fs.read* work (used in tests)
      // 'browserify-shim' wraps non-browserify modules
      // 'envify' makes process.env work
      // etc...
      transform: ['brfs']
    },

    // test results reporter to use
    // possible values: 'dots', 'progress'
    // available reporters: https://npmjs.org/browse/keyword/karma-reporter
    reporters: ['progress'],

    // web server port
    port: 9876,

    // enable / disable colors in the output (reporters and logs)
    colors: true,

    // level of logging
    // possible values: config.LOG_DISABLE || config.LOG_ERROR || config.LOG_WARN || config.LOG_INFO || config.LOG_DEBUG
    logLevel: config.LOG_INFO,

    // enable / disable watching file and executing tests whenever any file changes
    autoWatch: true,

    // start these browsers
    // available browser launchers: https://npmjs.org/browse/keyword/karma-launcher
    browsers: ['Chrome', 'Firefox'],

    // Continuous Integration mode
    // if true, Karma captures browsers, runs the tests and exits
    singleRun: false,

    // Concurrency level
    // how many browser should be started simultaneous
    concurrency: Infinity
  })
}


text:
import React from 'react';

class MyComponent1 extends React.Component {
  componentWillReceiveProps() {}
}

class MyComponent2 extends React.Component {
  shouldComponentUpdate() {}
}

class MyComponent3 extends React.Component {
  componentWillUpdate() {}
}

class MyComponent4 extends React.Component {
  componentDidUpdate() {}
}

const expression1 = () =>
  class extends React.Component {
    componentWillReceiveProps() {}
  }

const expression2 = () =>
  class extends React.Component {
    shouldComponentUpdate() {}
  }

const expression3 = () =>
  class extends React.Component {
    componentWillUpdate() {}
  }

const expression4 = () =>
  class extends React.Component {
    componentDidUpdate() {}
  }


text:
package org.apache.accumulo.server.util;

import static org.junit.Assert.*;

import java.util.concurrent.atomic.AtomicInteger;

import org.apache.accumulo.server.util.DefaultMap;
import org.junit.Test;

public class DefaultMapTest {

  @Test
  public void testDefaultMap() {
    Integer value = new DefaultMap<String,Integer>(0).get("test");
    assertNotNull(value);
    assertEquals(new Integer(0), value);
    value = new DefaultMap<String,Integer>(1).get("test");
    assertNotNull(value);
    assertEquals(new Integer(1), value);

    AtomicInteger canConstruct = new DefaultMap<String,AtomicInteger>(new AtomicInteger(1)).get("test");
    assertNotNull(canConstruct);
    assertEquals(new AtomicInteger(0).get(), canConstruct.get());

    DefaultMap<String,String> map = new DefaultMap<String,String>("");
    assertEquals(map.get("foo"), "");
    map.put("foo", "bar");
    assertEquals(map.get("foo"), "bar");
  }

}


text:
<!DOCTYPE html>

        <meta charset="utf-8">
        <title>A collection of simple picnicc examples</title>
        <meta name="viewport" content="width=device-width, initial-scale=1.0">
        <meta name="description" content="A colection of simple picnicc examples">
        <meta name="author" content="Alex Duloz - http://bitspushedaround.com">
        <link href="css/main.css" rel="stylesheet" type="text/css">

            myAwesomeFramework.css

            A collection of pincicc examples.

            The examples shown here are based on a incredibly simple, extremely basic CSS framework named myAwesomeFramework. The idea here is just to show you how picnicc operates and how you can interact with its API.

            View repo

                Form sent directly to the API

                Form sent directly to the API (error handled by picni.cc)

                Form sent directly to the API (error attached to the query string)

                Form sent using picnicc.form.js

                Form sent using picnicc.form.js with callbacks

                Form sent using picnicc.form.js (error handled by picnicc.form.js)

                Form sent + Build retrieved using picnicc.form.js


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

package com.twitter.heron.api;

import java.io.Serializable;

/**
 * A pair of values.
 *
 * @param <T1> the type of the first value
 * @param <T2> the type of the second value
 */
public final class Pair<T1, T2> implements Serializable {

  private static final long serialVersionUID = 3926373357946515821L;
  /**
   * The first value
   */
  private final T1 first;
  /**
   * The second value
   */
  private final T2 second;

  /**
   * Constructs a new pair of values
   *
   * @param first the first value
   * @param second the second value
   */
  private Pair(T1 first, T2 second) {
    this.first = first;
    this.second = second;
  }

  /**
   * Returns the first value in a pair.
   *
   * @return the first value
   */
  public T1 getFirst() {
    return first;
  }

  /**
   * Returns the second value in a pair.
   *
   * @return the second value
   */
  public T2 getSecond() {
    return second;
  }

  /**
   * Constructs a new pair of values.
   *
   * @param first the first value
   * @param second the second value
   * @param <T1> the type of the first value
   * @param <T2> the type of the second value
   * @return a new pair of values
   */
  public static <T1, T2> Pair<T1, T2> of(T1 first, T2 second) {
    return new Pair<>(first, second);
  }

  @Override
  public boolean equals(Object o) {
    if (this == o) {
      return true;
    }
    if (o == null || getClass() != o.getClass()) {
      return false;
    }

    Pair<?, ?> pair = (Pair<?, ?>) o;

    if (first != null ? !first.equals(pair.first) : pair.first != null) {
      return false;
    }
    return second != null ? second.equals(pair.second) : pair.second == null;

  }

  @Override
  public int hashCode() {
    int result = first != null ? first.hashCode() : 0;
    result = 31 * result + (second != null ? second.hashCode() : 0);
    return result;
  }

  @Override
  public String toString() {
    return "(" + first + ", " + second + ')';
  }
}


text:
<?php
namespace Dkd\PhpCmis\DataObjects;

use Dkd\PhpCmis\Data\FailedToDeleteDataInterface;

/**
 * FailedToDeleteData implementation.
 */
class FailedToDeleteData extends AbstractExtensionData implements FailedToDeleteDataInterface
{
    /**
     * @var string[]
     */
    protected $ids = [];

    /**
     * Returns the list of ids that could not be deleted.
     *
     * @param string[] $ids List of ids that could not be deleted
     */
    public function setIds(array $ids)
    {
        $this->ids = $ids;
    }

    /**
     * Returns the list of ids that could not be deleted.
     *
     * @return string[]
     */
    public function getIds()
    {
        return $this->ids;
    }
}


text:
#ifndef __ASM_PARAM_H
#define __ASM_PARAM_H

# define HZ		100

#define EXEC_PAGESIZE	4096

#ifndef NOGROUP
#define NOGROUP         (-1)
#endif

/* max length of hostname */
#define MAXHOSTNAMELEN  64

#endif


text:
package com.google.javascript.rhino.jstype;

import static com.google.common.truth.Truth.assertThat;

import com.google.javascript.rhino.testing.BaseJSTypeTestCase;
import org.junit.Test;
import org.junit.runner.RunWith;
import org.junit.runners.JUnit4;

@RunWith(JUnit4.class)
public class PrototypeObjectTypeTest extends BaseJSTypeTestCase {

  @Test
  public void testToString() {
    ObjectType type = registry.createAnonymousObjectType(null);
    assertThat(type.toString()).isEqualTo("{}");

    type.defineDeclaredProperty("foo", NUMBER_TYPE, null);
    assertThat(type.toString()).isEqualTo("{foo: number}");

    type.defineDeclaredProperty("bar", type, null);
    assertThat(type.toString()).isEqualTo("{bar: {...}, foo: number}");
  }
}


text:
/*----------------------------------------------------------------------------
 * Notice of Export Control Law
 * ===============================================
 * Huawei LiteOS may be subject to applicable export control laws and regulations, which might
 * include those applicable to Huawei LiteOS of U.S. and the country in which you are located.
 * Import, export and usage of Huawei LiteOS in any manner by you shall be in compliance with such
 * applicable export control laws and regulations.
 *---------------------------------------------------------------------------*/

/**@defgroup los_demo_entry System configuration items
 * @ingroup kernel
 */

#ifndef _LOS_DEMO_ENTRY_H
#define _LOS_DEMO_ENTRY_H

#include "los_typedef.h"

#include "los_demo_debug.h"

/* task schedule */
#include "los_api_task.h"
/* dynamic memory */
#include "los_api_dynamic_mem.h"
/* static memory */
#include "los_api_static_mem.h"
/* interrupt */
#include "los_api_interrupt.h"
/* message queue */
#include "los_api_msgqueue.h"
/* event  */
#include "los_api_event.h"
/* mutex */
#include "los_api_mutex.h"
/* semphore */
#include "los_api_sem.h"
/* sw timer */
#include "los_api_timer.h"
/* system tick */
#include "los_api_systick.h"
/* dlist */
#include "los_api_list.h"

/* test task schedule */
//#define LOS_KERNEL_TEST_TASK

/* test dynamic memory */
//#define LOS_KERNEL_TEST_MEM_DYNAMIC

/* test static memory */
//#define LOS_KERNEL_TEST_MEM_STATIC

/* test interrupt */
#define LOS_KERNEL_TEST_INTRRUPT

/* test Queue */
//#define LOS_KERNEL_TEST_QUEUE

/* test Event */
//#define LOS_KERNEL_TEST_EVENT

/* test Mutex */
//#define LOS_KERNEL_TEST_MUTEX

/* test Semphore */
//#define LOS_KERNEL_TEST_SEMPHORE

/* test sysTick */
//#define LOS_KERNEL_TEST_SYSTICK

/* test Timer1 */
//#define LOS_KERNEL_TEST_SWTIMER

/* test list */
//#define LOS_KERNEL_TEST_LIST

/* test ALL */
//#define LOS_KERNEL_TEST_ALL

extern void LOS_Demo_Entry(void);

#endif


text:
"""A tabular representation of a distribution for a game."""

from typing import Dict, Optional

from open_spiel.python.mfg import distribution
import pyspiel

DistributionDict = Dict[str, float]

class TabularDistribution(distribution.ParametricDistribution):
  """Distribution that uses a dictionary to store the values of the states."""

  def __init__(self, game: pyspiel.Game):
    self._distribution: DistributionDict = {}
    super().__init__(game)

  def value(self, state: pyspiel.State) -> float:
    return self.value_str(self.state_to_str(state))

  def value_str(self,
                state_str: str,
                default_value: Optional[float] = None) -> float:
    """Returns the probability of the distribution on the state string given.

    Args:
      state_str: A string.
      default_value: If not None, return this value if the state is not in the
        support of the distribution.

    Returns:
      A `float`.

    Raises:
      ValueError: If the state has not been seen by the distribution and no
        default value has been passed to the method.
    """
    if default_value is None:
      try:
        return self._distribution[state_str]
      except KeyError as e:
        raise ValueError(
            f"Distribution not computed for state {state_str}") from e
    return self._distribution.get(state_str, default_value)

  def get_params(self) -> DistributionDict:
    return self._distribution

  def set_params(self, params: DistributionDict):
    self._distribution = params

  def state_to_str(self, state: pyspiel.State) -> str:
    # TODO(author15): Consider switching to
    # state.mean_field_population(). For now, this does not matter in
    # practice since games don't have different observation strings for
    # different player IDs.
    return state.observation_string(pyspiel.PlayerId.DEFAULT_PLAYER_ID)

  @property
  def distribution(self) -> DistributionDict:
    return self._distribution