/**
 */
package ua.ansymo.hintco;


/**
 * <!-- begin-user-doc -->
 * A representation of the model object '<em><b>Power Bond Adaptation</b></em>'.
 * <!-- end-user-doc -->
 *
 * <p>
 * The following features are supported:
 * </p>
 * <ul>
 *   <li>{@link ua.ansymo.hintco.PowerBondAdaptation#getEffort <em>Effort</em>}</li>
 *   <li>{@link ua.ansymo.hintco.PowerBondAdaptation#getFlow <em>Flow</em>}</li>
 *   <li>{@link ua.ansymo.hintco.PowerBondAdaptation#getPOut <em>POut</em>}</li>
 *   <li>{@link ua.ansymo.hintco.PowerBondAdaptation#getPIn <em>PIn</em>}</li>
 *   <li>{@link ua.ansymo.hintco.PowerBondAdaptation#getName <em>Name</em>}</li>
 * </ul>
 *
 * @see ua.ansymo.hintco.HintcoPackage#getPowerBondAdaptation()
 * @model
 * @generated
 */
public interface PowerBondAdaptation extends UnitAdaptation {
	/**
	 * Returns the value of the '<em><b>Effort</b></em>' reference.
	 * <!-- begin-user-doc -->
	 * <p>
	 * If the meaning of the '<em>Effort</em>' reference isn't clear,
	 * there really should be more of a description here...
	 * </p>
	 * <!-- end-user-doc -->
	 * @return the value of the '<em>Effort</em>' reference.
	 * @see #setEffort(PortInstance)
	 * @see ua.ansymo.hintco.HintcoPackage#getPowerBondAdaptation_Effort()
	 * @model
	 * @generated
	 */
	PortInstance getEffort();

	/**
	 * Sets the value of the '{@link ua.ansymo.hintco.PowerBondAdaptation#getEffort <em>Effort</em>}' reference.
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @param value the new value of the '<em>Effort</em>' reference.
	 * @see #getEffort()
	 * @generated
	 */
	void setEffort(PortInstance value);

	/**
	 * Returns the value of the '<em><b>Flow</b></em>' reference.
	 * <!-- begin-user-doc -->
	 * <p>
	 * If the meaning of the '<em>Flow</em>' reference isn't clear,
	 * there really should be more of a description here...
	 * </p>
	 * <!-- end-user-doc -->
	 * @return the value of the '<em>Flow</em>' reference.
	 * @see #setFlow(PortInstance)
	 * @see ua.ansymo.hintco.HintcoPackage#getPowerBondAdaptation_Flow()
	 * @model
	 * @generated
	 */
	PortInstance getFlow();

	/**
	 * Sets the value of the '{@link ua.ansymo.hintco.PowerBondAdaptation#getFlow <em>Flow</em>}' reference.
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @param value the new value of the '<em>Flow</em>' reference.
	 * @see #getFlow()
	 * @generated
	 */
	void setFlow(PortInstance value);

	/**
	 * Returns the value of the '<em><b>POut</b></em>' reference.
	 * <!-- begin-user-doc -->
	 * <p>
	 * If the meaning of the '<em>POut</em>' reference isn't clear,
	 * there really should be more of a description here...
	 * </p>
	 * <!-- end-user-doc -->
	 * @return the value of the '<em>POut</em>' reference.
	 * @see #setPOut(OutputPortInstance)
	 * @see ua.ansymo.hintco.HintcoPackage#getPowerBondAdaptation_POut()
	 * @model
	 * @generated
	 */
	OutputPortInstance getPOut();

	/**
	 * Sets the value of the '{@link ua.ansymo.hintco.PowerBondAdaptation#getPOut <em>POut</em>}' reference.
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @param value the new value of the '<em>POut</em>' reference.
	 * @see #getPOut()
	 * @generated
	 */
	void setPOut(OutputPortInstance value);

	/**
	 * Returns the value of the '<em><b>PIn</b></em>' reference.
	 * <!-- begin-user-doc -->
	 * <p>
	 * If the meaning of the '<em>PIn</em>' reference isn't clear,
	 * there really should be more of a description here...
	 * </p>
	 * <!-- end-user-doc -->
	 * @return the value of the '<em>PIn</em>' reference.
	 * @see #setPIn(InputPortInstance)
	 * @see ua.ansymo.hintco.HintcoPackage#getPowerBondAdaptation_PIn()
	 * @model
	 * @generated
	 */
	InputPortInstance getPIn();

	/**
	 * Sets the value of the '{@link ua.ansymo.hintco.PowerBondAdaptation#getPIn <em>PIn</em>}' reference.
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @param value the new value of the '<em>PIn</em>' reference.
	 * @see #getPIn()
	 * @generated
	 */
	void setPIn(InputPortInstance value);

	/**
	 * Returns the value of the '<em><b>Name</b></em>' attribute.
	 * <!-- begin-user-doc -->
	 * <p>
	 * If the meaning of the '<em>Name</em>' attribute isn't clear,
	 * there really should be more of a description here...
	 * </p>
	 * <!-- end-user-doc -->
	 * @return the value of the '<em>Name</em>' attribute.
	 * @see ua.ansymo.hintco.HintcoPackage#getPowerBondAdaptation_Name()
	 * @model unique="false" transient="true" changeable="false" volatile="true" derived="true"
	 *        annotation="http://www.eclipse.org/emf/2002/GenModel get='&lt;%java.lang.String%&gt; _xifexpression = null;\nif (((this.getEffort() != null) &amp;&amp; (this.getFlow() != null)))\n{\n\t&lt;%java.lang.String%&gt; _identifier = this.getEffort().getIdentifier();\n\t&lt;%java.lang.String%&gt; _plus = (\"PBond_\" + _identifier);\n\t&lt;%java.lang.String%&gt; _plus_1 = (_plus + \"_\");\n\t&lt;%java.lang.String%&gt; _identifier_1 = this.getFlow().getIdentifier();\n\t&lt;%java.lang.String%&gt; _plus_2 = (_plus_1 + _identifier_1);\n\t&lt;%java.lang.String%&gt; _plus_3 = (_plus_2 + \"(w=\");\n\tint _weight = this.getWeight();\n\t&lt;%java.lang.String%&gt; _plus_4 = (_plus_3 + &lt;%java.lang.Integer%&gt;.valueOf(_weight));\n\t_xifexpression = (_plus_4 + \")\");\n}\nelse\n{\n\tint _weight_1 = this.getWeight();\n\t&lt;%java.lang.String%&gt; _plus_5 = (\"PBond(w=\" + &lt;%java.lang.Integer%&gt;.valueOf(_weight_1));\n\t_xifexpression = (_plus_5 + \")\");\n}\nreturn _xifexpression;'"
	 * @generated
	 */
	String getName();

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @model kind="operation" unique="false"
	 *        annotation="http://www.eclipse.org/emf/2002/GenModel body='&lt;%ua.ansymo.hintco.PowerBondAdaptation%&gt; _xblockexpression = null;\n{\n\t&lt;%ua.ansymo.hintco.PowerBondAdaptation%&gt; res = null;\n\tif (((this.getEffort() instanceof &lt;%ua.ansymo.hintco.InputPortInstance%&gt;) &amp;&amp; (this.getFlow() instanceof &lt;%ua.ansymo.hintco.OutputPortInstance%&gt;)))\n\t{\n\t\tfinal &lt;%org.eclipse.xtext.xbase.lib.Functions.Function1%&gt;&lt;&lt;%ua.ansymo.hintco.UnitInstance%&gt;, &lt;%java.lang.Iterable%&gt;&lt;&lt;%ua.ansymo.hintco.PowerBondAdaptation%&gt;&gt;&gt; _function = new &lt;%org.eclipse.xtext.xbase.lib.Functions.Function1%&gt;&lt;&lt;%ua.ansymo.hintco.UnitInstance%&gt;, &lt;%java.lang.Iterable%&gt;&lt;&lt;%ua.ansymo.hintco.PowerBondAdaptation%&gt;&gt;&gt;()\n\t\t{\n\t\t\tpublic &lt;%java.lang.Iterable%&gt;&lt;&lt;%ua.ansymo.hintco.PowerBondAdaptation%&gt;&gt; apply(final &lt;%ua.ansymo.hintco.UnitInstance%&gt; u)\n\t\t\t{\n\t\t\t\treturn &lt;%org.eclipse.xtext.xbase.lib.IteratorExtensions%&gt;.&lt;&lt;%ua.ansymo.hintco.PowerBondAdaptation%&gt;&gt;toIterable(&lt;%com.google.common.collect.Iterators%&gt;.&lt;&lt;%ua.ansymo.hintco.PowerBondAdaptation%&gt;&gt;filter(u.eAllContents(), &lt;%ua.ansymo.hintco.PowerBondAdaptation%&gt;.class));\n\t\t\t}\n\t\t};\n\t\tfinal &lt;%org.eclipse.xtext.xbase.lib.Functions.Function1%&gt;&lt;&lt;%ua.ansymo.hintco.PowerBondAdaptation%&gt;, &lt;%java.lang.Boolean%&gt;&gt; _function_1 = new &lt;%org.eclipse.xtext.xbase.lib.Functions.Function1%&gt;&lt;&lt;%ua.ansymo.hintco.PowerBondAdaptation%&gt;, &lt;%java.lang.Boolean%&gt;&gt;()\n\t\t{\n\t\t\tpublic &lt;%java.lang.Boolean%&gt; apply(final &lt;%ua.ansymo.hintco.PowerBondAdaptation%&gt; a)\n\t\t\t{\n\t\t\t\treturn &lt;%java.lang.Boolean%&gt;.valueOf(((a.getEffort() instanceof &lt;%ua.ansymo.hintco.OutputPortInstance%&gt;) &amp;&amp; (a.getFlow() instanceof &lt;%ua.ansymo.hintco.InputPortInstance%&gt;)));\n\t\t\t}\n\t\t};\n\t\tfinal &lt;%org.eclipse.xtext.xbase.lib.Functions.Function1%&gt;&lt;&lt;%ua.ansymo.hintco.PowerBondAdaptation%&gt;, &lt;%java.lang.Boolean%&gt;&gt; _function_2 = new &lt;%org.eclipse.xtext.xbase.lib.Functions.Function1%&gt;&lt;&lt;%ua.ansymo.hintco.PowerBondAdaptation%&gt;, &lt;%java.lang.Boolean%&gt;&gt;()\n\t\t{\n\t\t\tpublic &lt;%java.lang.Boolean%&gt; apply(final &lt;%ua.ansymo.hintco.PowerBondAdaptation%&gt; a)\n\t\t\t{\n\t\t\t\treturn &lt;%java.lang.Boolean%&gt;.valueOf((((&lt;%ua.ansymo.hintco.OutputPortInstance%&gt;) a.getEffort()).getValueTo().contains(&lt;%this%&gt;.getEffort()) &amp;&amp; (((&lt;%ua.ansymo.hintco.InputPortInstance%&gt;) a.getFlow()).getValueFrom() == &lt;%this%&gt;.getFlow())));\n\t\t\t}\n\t\t};\n\t\tres = &lt;%org.eclipse.xtext.xbase.lib.IterableExtensions%&gt;.&lt;&lt;%ua.ansymo.hintco.PowerBondAdaptation%&gt;&gt;findFirst(&lt;%org.eclipse.xtext.xbase.lib.IterableExtensions%&gt;.&lt;&lt;%ua.ansymo.hintco.PowerBondAdaptation%&gt;&gt;filter(&lt;%org.eclipse.xtext.xbase.lib.IterableExtensions%&gt;.&lt;&lt;%ua.ansymo.hintco.UnitInstance%&gt;, &lt;%ua.ansymo.hintco.PowerBondAdaptation%&gt;&gt;flatMap(this.getUnit().getScenario().getCosimunits(), _function), _function_1), _function_2);\n\t}\n\telse\n\t{\n\t\tif (((this.getEffort() instanceof &lt;%ua.ansymo.hintco.OutputPortInstance%&gt;) &amp;&amp; (this.getFlow() instanceof &lt;%ua.ansymo.hintco.InputPortInstance%&gt;)))\n\t\t{\n\t\t\tfinal &lt;%org.eclipse.xtext.xbase.lib.Functions.Function1%&gt;&lt;&lt;%ua.ansymo.hintco.UnitInstance%&gt;, &lt;%java.lang.Iterable%&gt;&lt;&lt;%ua.ansymo.hintco.PowerBondAdaptation%&gt;&gt;&gt; _function_3 = new &lt;%org.eclipse.xtext.xbase.lib.Functions.Function1%&gt;&lt;&lt;%ua.ansymo.hintco.UnitInstance%&gt;, &lt;%java.lang.Iterable%&gt;&lt;&lt;%ua.ansymo.hintco.PowerBondAdaptation%&gt;&gt;&gt;()\n\t\t\t{\n\t\t\t\tpublic &lt;%java.lang.Iterable%&gt;&lt;&lt;%ua.ansymo.hintco.PowerBondAdaptation%&gt;&gt; apply(final &lt;%ua.ansymo.hintco.UnitInstance%&gt; u)\n\t\t\t\t{\n\t\t\t\t\treturn &lt;%org.eclipse.xtext.xbase.lib.IteratorExtensions%&gt;.&lt;&lt;%ua.ansymo.hintco.PowerBondAdaptation%&gt;&gt;toIterable(&lt;%com.google.common.collect.Iterators%&gt;.&lt;&lt;%ua.ansymo.hintco.PowerBondAdaptation%&gt;&gt;filter(u.eAllContents(), &lt;%ua.ansymo.hintco.PowerBondAdaptation%&gt;.class));\n\t\t\t\t}\n\t\t\t};\n\t\t\tfinal &lt;%org.eclipse.xtext.xbase.lib.Functions.Function1%&gt;&lt;&lt;%ua.ansymo.hintco.PowerBondAdaptation%&gt;, &lt;%java.lang.Boolean%&gt;&gt; _function_4 = new &lt;%org.eclipse.xtext.xbase.lib.Functions.Function1%&gt;&lt;&lt;%ua.ansymo.hintco.PowerBondAdaptation%&gt;, &lt;%java.lang.Boolean%&gt;&gt;()\n\t\t\t{\n\t\t\t\tpublic &lt;%java.lang.Boolean%&gt; apply(final &lt;%ua.ansymo.hintco.PowerBondAdaptation%&gt; a)\n\t\t\t\t{\n\t\t\t\t\treturn &lt;%java.lang.Boolean%&gt;.valueOf(((a.getEffort() instanceof &lt;%ua.ansymo.hintco.InputPortInstance%&gt;) &amp;&amp; (a.getFlow() instanceof &lt;%ua.ansymo.hintco.OutputPortInstance%&gt;)));\n\t\t\t\t}\n\t\t\t};\n\t\t\tfinal &lt;%org.eclipse.xtext.xbase.lib.Functions.Function1%&gt;&lt;&lt;%ua.ansymo.hintco.PowerBondAdaptation%&gt;, &lt;%java.lang.Boolean%&gt;&gt; _function_5 = new &lt;%org.eclipse.xtext.xbase.lib.Functions.Function1%&gt;&lt;&lt;%ua.ansymo.hintco.PowerBondAdaptation%&gt;, &lt;%java.lang.Boolean%&gt;&gt;()\n\t\t\t{\n\t\t\t\tpublic &lt;%java.lang.Boolean%&gt; apply(final &lt;%ua.ansymo.hintco.PowerBondAdaptation%&gt; a)\n\t\t\t\t{\n\t\t\t\t\treturn &lt;%java.lang.Boolean%&gt;.valueOf(((((&lt;%ua.ansymo.hintco.InputPortInstance%&gt;) a.getEffort()).getValueFrom() == &lt;%this%&gt;.getEffort()) &amp;&amp; ((&lt;%ua.ansymo.hintco.OutputPortInstance%&gt;) a.getFlow()).getValueTo().contains(&lt;%this%&gt;.getFlow())));\n\t\t\t\t}\n\t\t\t};\n\t\t\tres = &lt;%org.eclipse.xtext.xbase.lib.IterableExtensions%&gt;.&lt;&lt;%ua.ansymo.hintco.PowerBondAdaptation%&gt;&gt;findFirst(&lt;%org.eclipse.xtext.xbase.lib.IterableExtensions%&gt;.&lt;&lt;%ua.ansymo.hintco.PowerBondAdaptation%&gt;&gt;filter(&lt;%org.eclipse.xtext.xbase.lib.IterableExtensions%&gt;.&lt;&lt;%ua.ansymo.hintco.UnitInstance%&gt;, &lt;%ua.ansymo.hintco.PowerBondAdaptation%&gt;&gt;flatMap(this.getUnit().getScenario().getCosimunits(), _function_3), _function_4), _function_5);\n\t\t}\n\t\telse\n\t\t{\n\t\t\tthrow new &lt;%java.lang.RuntimeException%&gt;(\"Invalid effort and flow in power bond adaptation\");\n\t\t}\n\t}\n\tif ((res == null))\n\t{\n\t\tthrow new &lt;%java.lang.RuntimeException%&gt;(\"Power bond adaptation has no dual\");\n\t}\n\t_xblockexpression = res;\n}\nreturn _xblockexpression;'"
	 * @generated
	 */
	PowerBondAdaptation getDual();

} // PowerBondAdaptation
