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


Java PieChartModel类代码示例

本文整理汇总了Java中org.primefaces.model.chart.PieChartModel的典型用法代码示例。如果您正苦于以下问题:Java PieChartModel类的具体用法?Java PieChartModel怎么用?Java PieChartModel使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。


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

示例1: createPieModel

import org.primefaces.model.chart.PieChartModel; //导入依赖的package包/类
private void createPieModel() {
pieModelUS = new PieChartModel();
pieModelUK = new PieChartModel();
 
      for(AccountSummary obj:accountsInfo){
      	pieModelUS.set(obj.getAccountType(),new Double(obj.getBalanceUS()));
      	pieModelUK.set(obj.getAccountType(),new Double(obj.getBalanceUK()));
      }
      
      pieModelUS.setTitle("USD Marketvalue");
      pieModelUS.setLegendPosition("w");
      pieModelUS.setShowDataLabels(true);
      
      pieModelUK.setTitle("UK Marketvalue");
      pieModelUK.setLegendPosition("e");
      pieModelUK.setFill(false);
      
      pieModelUK.setShowDataLabels(true);
      pieModelUK.setSliceMargin(5);
      //pieModelUK.setDiameter(150);
  }
 
开发者ID:sudheerj,项目名称:primefaces-blueprints,代码行数:22,代码来源:AccountSummaryController.java

示例2: initPieModel

import org.primefaces.model.chart.PieChartModel; //导入依赖的package包/类
private void initPieModel() {
/* 80 */     this.pieModel = new PieChartModel();
/*    */ 
/* 82 */     this.pieModel.set("Brand 1", Integer.valueOf(540));
/* 83 */     this.pieModel.set("Brand 2", Integer.valueOf(325));
/* 84 */     this.pieModel.set("Brand 3", Integer.valueOf(702));
/* 85 */     this.pieModel.set("Brand 4", Integer.valueOf(421));
/*    */ 
/* 87 */     this.pieModel.setExtender("skinPie");
/*    */   }
 
开发者ID:marlonalexis,项目名称:Multicentro_Mascotas,代码行数:11,代码来源:ChartView.java

示例3: preRender

import org.primefaces.model.chart.PieChartModel; //导入依赖的package包/类
public void preRender() {
	this.model = new LineChartModel();
	this.model.setTitle("Pedidos criados");
	this.model.setAnimate(true);

	this.model.setLegendPosition("e");

	this.model.getAxes().put(AxisType.X, new CategoryAxis("Datas"));

	Axis yAxis = this.model.getAxis(AxisType.Y);
	yAxis.setLabel("Valores");
	yAxis.setMin(0);
	// yAxis.setMax(1100);

	adicionarSeries("Todos os pedidos", null);
	adicionarSeries("Meus pedidos", this.usuarioLogado.getUsuario());

	// ModelPie
	this.modelPie = new PieChartModel();

	Map<String, BigDecimal> valoresPorUsuario = this.pedidos.valoresTotaisPorVendedor();

	for (String usuario : valoresPorUsuario.keySet()) {
		this.modelPie.set(usuario, valoresPorUsuario.get(usuario));
	}

	this.modelPie.setTitle("Totais por Vendedor");
	this.modelPie.setLegendPosition("w");
	this.modelPie.setShowDataLabels(true);
	this.modelPie.setShadow(true);
}
 
开发者ID:fabiohxcx,项目名称:PedidoVenda,代码行数:32,代码来源:GraficosPedidosCriadosBean.java

示例4: preencherDadosGrafico

import org.primefaces.model.chart.PieChartModel; //导入依赖的package包/类
private void preencherDadosGrafico() {

		dadosGrafico = new PieChartModel();

		int contador = 1;
		for (RecursoDTO recurso : dados) {
			String descricaoTopico = criarDescricao(contador, recurso);
			int participacoes = recurso.getQuantidade();
			totalDePostagens += participacoes;
			dadosGrafico.set(descricaoTopico, participacoes);
			contador++;
		}
		
	}
 
开发者ID:camaradosdeputadosoficial,项目名称:edemocracia,代码行数:15,代码来源:GraficoBean.java

示例5: createPieModel

import org.primefaces.model.chart.PieChartModel; //导入依赖的package包/类
private void createPieModel() {
    pieModel = new PieChartModel();
    for (Hotel h : hotelService.listHotel()) {
        if (h.getComments().size() != 0) {
            pieModel.set(h.getName(), h.getComments().size());
        }
    }
}
 
开发者ID:ilya-murzinov,项目名称:hotel-booking,代码行数:9,代码来源:ChartBean.java

示例6: PrimeChartBean

import org.primefaces.model.chart.PieChartModel; //导入依赖的package包/类
public PrimeChartBean(){
	pieModel1 = new PieChartModel();
       
       pieModel1.set("Brand 1", 540);
       pieModel1.set("Brand 2", 325);
       pieModel1.set("Brand 3", 702);
       pieModel1.set("Brand 4", 421);
        
       pieModel1.setTitle("Simple Pie");
       pieModel1.setLegendPosition("w");
}
 
开发者ID:tdduy,项目名称:primefaces_component-portlet,代码行数:12,代码来源:PrimeChartBean.java

示例7: createPieModel

import org.primefaces.model.chart.PieChartModel; //导入依赖的package包/类
private void createPieModel()
{
	pieModel = new PieChartModel();

	pieModel.set("Brand A", 540);
	pieModel.set("Brand B", 325);
	pieModel.set("Brand C", 702);
	pieModel.set("Brand D", 421);
}
 
开发者ID:ova2,项目名称:jsf-portal,代码行数:10,代码来源:ChartBeanB.java

示例8: createPieModel

import org.primefaces.model.chart.PieChartModel; //导入依赖的package包/类
private void createPieModel()
{
	pieModel = new PieChartModel();

	pieModel.set("Brand 1", 540);
	pieModel.set("Brand 2", 325);
	pieModel.set("Brand 3", 702);
	pieModel.set("Brand 4", 421);
}
 
开发者ID:ova2,项目名称:jsf-portal,代码行数:10,代码来源:ChartBeanA.java

示例9: getLivePieModel

import org.primefaces.model.chart.PieChartModel; //导入依赖的package包/类
public PieChartModel getLivePieModel() {
      int random1 = (int)(Math.random() * 1000);
int random2 = (int)(Math.random() * 1000);

livePieModel.getData().put("Candidate 1", random1);
      livePieModel.getData().put("Candidate 2", random2);
      
      return livePieModel;
  }
 
开发者ID:websphere,项目名称:PrimefacesShowcase,代码行数:10,代码来源:ChartBean.java

示例10: createPieModel

import org.primefaces.model.chart.PieChartModel; //导入依赖的package包/类
private void createPieModel() {
    pieModel = new PieChartModel();
    
    pieModel.set("Brand 1", 540);
    pieModel.set("Brand 2", 325);
    pieModel.set("Brand 3", 702);
    pieModel.set("Brand 4", 421);
}
 
开发者ID:websphere,项目名称:PrimefacesShowcase,代码行数:9,代码来源:ChartBean.java

示例11: getPieModel

import org.primefaces.model.chart.PieChartModel; //导入依赖的package包/类
public PieChartModel getPieModel() {
/* 44 */     return this.pieModel;
/*    */   }
 
开发者ID:marlonalexis,项目名称:Multicentro_Mascotas,代码行数:4,代码来源:ChartView.java

示例12: getPieModel1

import org.primefaces.model.chart.PieChartModel; //导入依赖的package包/类
public PieChartModel getPieModel1() {
	return pieModel1.getPoll();
}
 
开发者ID:Arquisoft,项目名称:Voting_2b,代码行数:4,代码来源:ShowResultsP.java

示例13: getPoll

import org.primefaces.model.chart.PieChartModel; //导入依赖的package包/类
public PieChartModel getPoll(){
	return pieModel1;
}
 
开发者ID:Arquisoft,项目名称:Voting_2b,代码行数:4,代码来源:PiePoll.java

示例14: getPieModel1

import org.primefaces.model.chart.PieChartModel; //导入依赖的package包/类
public PieChartModel getPieModel1() {
	return pieModel1;
}
 
开发者ID:Arquisoft,项目名称:VoteCounting_2b,代码行数:4,代码来源:BeanMostrarResultados.java

示例15: getModelPie

import org.primefaces.model.chart.PieChartModel; //导入依赖的package包/类
public PieChartModel getModelPie() {
	return this.modelPie;
}
 
开发者ID:fabiohxcx,项目名称:PedidoVenda,代码行数:4,代码来源:GraficosPedidosCriadosBean.java


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