当前位置: 首页>>代码示例>>Java>>正文


Java ResourceDescriptor.getReferenceUri方法代码示例

本文整理汇总了Java中com.jaspersoft.jasperserver.api.metadata.xml.domain.impl.ResourceDescriptor.getReferenceUri方法的典型用法代码示例。如果您正苦于以下问题:Java ResourceDescriptor.getReferenceUri方法的具体用法?Java ResourceDescriptor.getReferenceUri怎么用?Java ResourceDescriptor.getReferenceUri使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在com.jaspersoft.jasperserver.api.metadata.xml.domain.impl.ResourceDescriptor的用法示例。


在下文中一共展示了ResourceDescriptor.getReferenceUri方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: getReference

import com.jaspersoft.jasperserver.api.metadata.xml.domain.impl.ResourceDescriptor; //导入方法依赖的package包/类
public static ResourceDescriptor getReference(IProgressMonitor monitor, ANode root, ResourceDescriptor rd) throws Exception {
	MServerProfile sp = (MServerProfile) root.getRoot();
	if (rd.getReferenceUri() != null) {
		String ref = rd.getReferenceUri();
		int ldel = ref.lastIndexOf("/");
		String pfolder = ref.substring(0, ldel - 1);
		String file = ref.substring(ldel + 1, ref.length());

		ResourceDescriptor r = new ResourceDescriptor();
		r.setParentFolder(pfolder);
		r.setName(file);
		r.setUriString(rd.getReferenceUri());
		r.setWsType(ResourceDescriptor.TYPE_CONTENT_RESOURCE);
		return sp.getWsClient(monitor).get(monitor, r, null);
	}
	return null;
}
 
开发者ID:OpenSoftwareSolutions,项目名称:PDFReporter-Studio,代码行数:18,代码来源:WSClientHelper.java

示例2: cascadeInputControls

import com.jaspersoft.jasperserver.api.metadata.xml.domain.impl.ResourceDescriptor; //导入方法依赖的package包/类
@Override
public List<ResourceDescriptor> cascadeInputControls(ResourceDescriptor runit, List<ResourceDescriptor> ics, IProgressMonitor monitor) throws Exception {
	String dsUri = null;
	for (ResourceDescriptor sub_rd : runit.getChildren()) {
		String wsType = sub_rd.getWsType();
		if (wsType.equals(ResourceDescriptor.TYPE_DATASOURCE) && sub_rd.getIsReference())
			dsUri = sub_rd.getReferenceUri();
		else if (SelectorDatasource.isDatasource(sub_rd))
			dsUri = sub_rd.getUriString();
	}
	String ruri = runit.getUriString();
	List<ResourceDescriptor> res = new ArrayList<ResourceDescriptor>();
	for (ResourceDescriptor rd : ics)
		res.add(updateControl(ruri, dsUri, rd, monitor));
	return res;
}
 
开发者ID:OpenSoftwareSolutions,项目名称:PDFReporter-Studio,代码行数:17,代码来源:SoapConnection.java

示例3: Proxy

import com.jaspersoft.jasperserver.api.metadata.xml.domain.impl.ResourceDescriptor; //导入方法依赖的package包/类
public Proxy(ResourceDescriptor rd) {
	this.rd = rd;
	if (rd.getIsReference()) {
		refuri = rd.getReferenceUri();
		name = refuri.substring(refuri.lastIndexOf("/") + 1); //$NON-NLS-1$
	} else
		name = rd.getName();
	alias = ResourceDescriptorUtil.getProperty("PROP_DATASOURCE_SUB_DS_ID", rd.getProperties());
}
 
开发者ID:OpenSoftwareSolutions,项目名称:PDFReporter-Studio,代码行数:10,代码来源:DatasourceVDSPageContent.java

示例4: initInputControls

import com.jaspersoft.jasperserver.api.metadata.xml.domain.impl.ResourceDescriptor; //导入方法依赖的package包/类
@Override
public ResourceDescriptor initInputControls(String uri, IProgressMonitor monitor) throws Exception {
	ResourceDescriptor rdrepunit = WSClientHelper.getReportUnit(monitor, uri);
	// List<ResourceDescriptor> list = list(monitor, rdrepunit);
	List<ResourceDescriptor> inputcontrols = new ArrayList<ResourceDescriptor>();
	Set<String> icNames = new HashSet<String>();
	String dsUri = null;
	for (ResourceDescriptor sub_rd : rdrepunit.getChildren()) {
		String wsType = sub_rd.getWsType();
		if (wsType.equals(ResourceDescriptor.TYPE_INPUT_CONTROL)) {
			inputcontrols.add(sub_rd);
			icNames.add(sub_rd.getName());
		} else if (wsType.equals(ResourceDescriptor.TYPE_DATASOURCE) && sub_rd.getIsReference())
			dsUri = sub_rd.getReferenceUri();
		else if (SelectorDatasource.isDatasource(sub_rd))
			dsUri = sub_rd.getUriString();
	}

	for (int i = 0; i < inputcontrols.size(); ++i) {
		ResourceDescriptor ic = inputcontrols.get(i);
		if (InputControlsManager.isICQuery(ic)) {
			String dsUriQuery = getDataSourceQueryURI(dsUri, ic);
			ic.setResourceProperty(ResourceDescriptor.PROP_QUERY_DATA, null);
			// Ask to add values to the control....
			List<Argument> args = new ArrayList<Argument>();
			args.add(new Argument(Argument.IC_GET_QUERY_DATA, dsUriQuery));
			args.add(new Argument(Argument.RU_REF_URI, uri));
			ic = client.get(ic, null, args);
			cascadingDependencies(ic, icNames);
		} else if (InputControlsManager.isICListOfValues(ic) && !ic.getChildren().isEmpty()) {
			ResourceDescriptor rd2 = (ResourceDescriptor) ic.getChildren().get(0);
			if (rd2.getWsType().equals(ResourceDescriptor.TYPE_REFERENCE)) {
				ResourceDescriptor tmpRd = new ResourceDescriptor();
				tmpRd.setUriString(rd2.getReferenceUri());
				tmpRd = get(monitor, tmpRd, null);
				ic.setListOfValues(tmpRd.getListOfValues());
			} else
				ic.setListOfValues(rd2.getListOfValues());
		}
		for (int j = 0; j < rdrepunit.getChildren().size(); j++) {
			ResourceDescriptor r = rdrepunit.getChildren().get(j);
			if (r.getName() != null && r.getName().equals(ic.getName()))
				rdrepunit.getChildren().set(j, ic);
		}
	}
	return rdrepunit;
}
 
开发者ID:OpenSoftwareSolutions,项目名称:PDFReporter-Studio,代码行数:48,代码来源:SoapConnection.java


注:本文中的com.jaspersoft.jasperserver.api.metadata.xml.domain.impl.ResourceDescriptor.getReferenceUri方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。