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


Java AccessRestriction类代码示例

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


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

示例1: getTotalStored

import appeng.api.config.AccessRestriction; //导入依赖的package包/类
public double getTotalStored() {

            double nodePower = 0;

            if (node != null) {
                for (IGridNode n : node.getGrid().getNodes()) {
                    if (n != node) {
                        IGridHost host = n.getGridBlock().getMachine();
                        if (host instanceof IAEPowerStorage) {
                            IAEPowerStorage storage = (IAEPowerStorage) host;
                            if (storage.isAEPublicPowerStorage()
                                    && (storage.getPowerFlow() == AccessRestriction.READ || storage.getPowerFlow() == AccessRestriction.READ_WRITE))
                                nodePower += storage.getAECurrentPower();
                        }
                    }
                }
            }

            return Math.min(getEnergyBuffer() + nodePower, getEnergyBufferSize());// FIXME
        }
 
开发者ID:amadornes,项目名称:Framez,代码行数:21,代码来源:MotorModifierAE2.java

示例2: HandlerEssentiaStorageBusBase

import appeng.api.config.AccessRestriction; //导入依赖的package包/类
/**
 * Creates the handler.
 *
 * @param part
 */
public HandlerEssentiaStorageBusBase( final PartEssentiaStorageBus part )
{
	// Set the part
	this.partStorageBus = part;

	// Set to full read/write access.
	this.access = AccessRestriction.READ_WRITE;

	if( part != null )
	{
		// Set the source
		this.machineSource = new MachineSource( part );
	}
}
 
开发者ID:Nividica,项目名称:ThaumicEnergistics,代码行数:20,代码来源:HandlerEssentiaStorageBusBase.java

示例3: hasSecurityPermission

import appeng.api.config.AccessRestriction; //导入依赖的package包/类
protected boolean hasSecurityPermission()
{
	// Is our access restricted to read-only or no access?
	if( ( this.access == AccessRestriction.READ ) || ( this.access == AccessRestriction.NO_ACCESS ) )
	{
		// Not allowed to insert
		return false;
	}
	return true;
}
 
开发者ID:Nividica,项目名称:ThaumicEnergistics,代码行数:11,代码来源:HandlerEssentiaStorageBusBase.java

示例4: getAccess

import appeng.api.config.AccessRestriction; //导入依赖的package包/类
@Override
@Optional.Method(modid = ModIds.AE2)
public AccessRestriction getAccess(){
    return AccessRestriction.READ;
}
 
开发者ID:TeamPneumatic,项目名称:pnc-repressurized,代码行数:6,代码来源:SemiBlockRequester.java

示例5: getPowerFlow

import appeng.api.config.AccessRestriction; //导入依赖的package包/类
@Override
public AccessRestriction getPowerFlow() {

    return AccessRestriction.WRITE;
}
 
开发者ID:amadornes,项目名称:Framez,代码行数:6,代码来源:MotorModifierAE2.java

示例6: getAccess

import appeng.api.config.AccessRestriction; //导入依赖的package包/类
@Override
public AccessRestriction getAccess()
{
	return getHandler().getAccess();
}
 
开发者ID:amadornes,项目名称:Framez,代码行数:6,代码来源:MEMonitorHandler.java

示例7: getAccess

import appeng.api.config.AccessRestriction; //导入依赖的package包/类
@Override
public AccessRestriction getAccess()
{
	return this.getHandler().getAccess();
}
 
开发者ID:austinv11,项目名称:PeripheralsPlusPlus,代码行数:6,代码来源:MEMonitorHandler.java

示例8: getAccess

import appeng.api.config.AccessRestriction; //导入依赖的package包/类
@Override
public AccessRestriction getAccess() {
    return getHandler().getAccess();
}
 
开发者ID:AgileMods,项目名称:MateriaMuto,代码行数:5,代码来源:MEMonitorHandler.java

示例9: getAccess

import appeng.api.config.AccessRestriction; //导入依赖的package包/类
/**
 * Returns the access restrictions, if any, imposed on the storage bus.
 */
@Override
public AccessRestriction getAccess()
{
	return this.access;
}
 
开发者ID:Nividica,项目名称:ThaumicEnergistics,代码行数:9,代码来源:HandlerEssentiaStorageBusBase.java

示例10: getAccess

import appeng.api.config.AccessRestriction; //导入依赖的package包/类
/**
 * Mode required to access the cell.
 */
@Override
public AccessRestriction getAccess()
{
	return AccessRestriction.READ_WRITE;
}
 
开发者ID:Nividica,项目名称:ThaumicEnergistics,代码行数:9,代码来源:HandlerItemEssentiaCell.java

示例11: getAccess

import appeng.api.config.AccessRestriction; //导入依赖的package包/类
@Override
public AccessRestriction getAccess()
{
    return AccessRestriction.READ_WRITE;
}
 
开发者ID:Dynious,项目名称:RefinedRelocation,代码行数:6,代码来源:TileMESortingInterface.java

示例12: getPowerFlow

import appeng.api.config.AccessRestriction; //导入依赖的package包/类
/**
 * Control the power flow by telling what the network can do, either add? or subtract? or both!
 * 
 * @return access restriction what the network can do
 */
public AccessRestriction getPowerFlow();
 
开发者ID:amadornes,项目名称:Framez,代码行数:7,代码来源:IAEPowerStorage.java

示例13: getPowerFlow

import appeng.api.config.AccessRestriction; //导入依赖的package包/类
/**
 * Control the power flow by telling what the network can do, either add? or
 * subtract? or both!
 * 
 * @return access restriction of network
 */
public AccessRestriction getPowerFlow(ItemStack is);
 
开发者ID:amadornes,项目名称:Framez,代码行数:8,代码来源:IAEItemPowerStorage.java

示例14: getAccess

import appeng.api.config.AccessRestriction; //导入依赖的package包/类
/**
 * determine if items can be injected/extracted.
 * 
 * @return the access
 */
public AccessRestriction getAccess();
 
开发者ID:amadornes,项目名称:Framez,代码行数:7,代码来源:IMEInventoryHandler.java

示例15: getPowerFlow

import appeng.api.config.AccessRestriction; //导入依赖的package包/类
/**
 * Control the power flow by telling what the network can do, either add? or subtract? or both!
 *
 * @return
 */
public AccessRestriction getPowerFlow();
 
开发者ID:AgileMods,项目名称:MateriaMuto,代码行数:7,代码来源:IAEPowerStorage.java


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