Package com.denimgroup.threadfix.service.defects.utils.versionone

Examples of com.denimgroup.threadfix.service.defects.utils.versionone.Assets$Asset$Relation


        String result = restUtils.getUrlAsString(getUrlWithRest() +
                        "Member?where=Username='" + getUrlEncodedUsername() + "'&sel=Scopes",
                getUsername(), getPassword());
        if (result != null) {
            Assets assets = MarshallingUtils.marshal(Assets.class, result);
            if (assets != null && assets.getAssets() != null) {
                for (Assets.Asset asset : assets.getAssets()) {
                    if (asset != null && asset.getAttributes() != null && asset.getAttributes().size() > 0) {
                        if (asset.getAttributes().get(0).getMixed() != null)
                            projectList.addAll(asset.getAttributes().get(0).getMixed());
                        if (asset.getAttributes().get(0).getValues() != null)
                            projectList.addAll(asset.getAttributes().get(0).getValues());
View Full Code Here


    private List<Assets.Asset> getAssets(String url) {
        List<Assets.Asset> assetList = list();

        String result = restUtils.getUrlAsString(url, getUsername(), getPassword());
        if (result != null) {
            Assets assets = MarshallingUtils.marshal(Assets.class, result);
            if (assets != null && assets.getAssets() != null) {
                assetList = assets.getAssets();
            }
        }
        return assetList;
    }
View Full Code Here

        return newMock(JavaScriptSupport.class);
    }

    protected final Asset mockAsset(String assetURL)
    {
        Asset asset = mockAsset();

        train_toClientURL(asset, assetURL);

        return asset;
    }
View Full Code Here

    @Test
    public void add_script_link_by_asset()
    {
        JavaScriptSupport js = mockJavaScriptSupport();
        Asset asset = mockAsset();

        js.importJavaScriptLibrary(asset);

        replay();
View Full Code Here

    public void add_classpath_script_link()
    {
        String path = "${root}/foo/bar.pdf";
        String expanded = "org/apache/tapestry5/foo/bar.pdf";

        Asset asset = mockAsset();
        SymbolSource source = mockSymbolSource();
        AssetSource assetSource = mockAssetSource();
        JavaScriptSupport js = mockJavaScriptSupport();

        train_expandSymbols(source, path, expanded);
View Full Code Here

    @Test
    public void add_stylesheet_link_by_asset()
    {
        String media = "print";
        JavaScriptSupport javascriptSupport = mockJavaScriptSupport();
        Asset asset = mockAsset("foo.css");

        javascriptSupport.importStylesheet(new StylesheetLink("foo.css", new StylesheetOptions(media)));

        replay();
View Full Code Here

        DocumentLinker linker = mockDocumentLinker();
        JavaScriptStackSource stackSource = mockJavaScriptStackSource();
        JavaScriptStackPathConstructor pathConstructor = mockJavaScriptStackPathConstructor();
        trainForEmptyCoreStack(linker, stackSource, pathConstructor);

        Asset library = mockAsset("mylib.js");

        linker.addScriptLink("mylib.js");

        replay();
View Full Code Here

        DocumentLinker linker = mockDocumentLinker();
        JavaScriptStackSource stackSource = mockJavaScriptStackSource();
        JavaScriptStackPathConstructor pathConstructor = mockJavaScriptStackPathConstructor();
        trainForEmptyCoreStack(linker, stackSource, pathConstructor);

        Asset library1 = mockAsset("mylib1.js");
        Asset library2 = mockAsset("mylib2.js");

        linker.addScriptLink("mylib1.js");
        linker.addScriptLink("mylib2.js");

        replay();
View Full Code Here

    @Test
    public void import_stylesheet_as_asset()
    {
        DocumentLinker linker = mockDocumentLinker();
        Asset stylesheet = mockAsset("style.css");

        StylesheetLink link = new StylesheetLink("style.css");
        linker.addStylesheetLink(link);

        replay();
View Full Code Here

    private void addScriptLinkFromClasspath(String path)
    {
        String expanded = symbolSource.expandSymbols(path);

        Asset asset = assetSource.getAsset(null, expanded, null);

        addScriptLink(asset);
    }
View Full Code Here

TOP

Related Classes of com.denimgroup.threadfix.service.defects.utils.versionone.Assets$Asset$Relation

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.