1 /* 2 * Copyright [2006] [University Corporation for Advanced Internet Development, Inc.] 3 * 4 * Licensed under the Apache License, Version 2.0 (the "License"); 5 * you may not use this file except in compliance with the License. 6 * You may obtain a copy of the License at 7 * 8 * http://www.apache.org/licenses/LICENSE-2.0 9 * 10 * Unless required by applicable law or agreed to in writing, software 11 * distributed under the License is distributed on an "AS IS" BASIS, 12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 * See the License for the specific language governing permissions and 14 * limitations under the License. 15 */ 16 17 package org.opensaml.xml.encryption; 18 19 import javax.xml.namespace.QName; 20 21 import org.opensaml.xml.ElementExtensibleXMLObject; 22 import org.opensaml.xml.util.XMLConstants; 23 import org.opensaml.xml.validation.ValidatingXMLObject; 24 25 /** 26 * XMLObject representing XML Encryption, version 20021210, AgreementMethod element. 27 */ 28 public interface AgreementMethod extends ValidatingXMLObject, ElementExtensibleXMLObject { 29 30 /** Element local name. */ 31 public static final String DEFAULT_ELEMENT_LOCAL_NAME = "AgreementMethod"; 32 33 /** Default element name. */ 34 public static final QName DEFAULT_ELEMENT_NAME = new QName(XMLConstants.XMLENC_NS, DEFAULT_ELEMENT_LOCAL_NAME, 35 XMLConstants.XMLENC_PREFIX); 36 37 /** Local name of the XSI type. */ 38 public static final String TYPE_LOCAL_NAME = "AgreementMethodType"; 39 40 /** QName of the XSI type. */ 41 public static final QName TYPE_NAME = new QName(XMLConstants.XMLENC_NS, TYPE_LOCAL_NAME, 42 XMLConstants.XMLENC_PREFIX); 43 44 /** Algorithm attribute name. */ 45 public static final String ALGORITHM_ATTRIBUTE_NAME = "Algorithm"; 46 47 /** 48 * Gets the algorithm URI attribute value for this agreement method. 49 * 50 * @return the algorithm URI attribute value 51 */ 52 public String getAlgorithm(); 53 54 /** 55 * Sets the algorithm URI attribute value for this agreement method. 56 * 57 * @param newAlgorithm the new algorithm URI attribute value 58 */ 59 public void setAlgorithm(String newAlgorithm); 60 61 /** 62 * Get the nonce child element used to introduce variability into the generation of keying material. 63 * 64 * @return the KA-Nonce child element 65 */ 66 public KANonce getKANonce(); 67 68 /** 69 * Set the nonce child element used to introduce variability into the generation of keying material. 70 * 71 * @param newKANonce the new KA-Nonce child element 72 */ 73 public void setKANonce(KANonce newKANonce); 74 75 /** 76 * Get the child element containing the key generation material for the originator. 77 * 78 * @return the OriginatorKeyInfo child element 79 */ 80 public OriginatorKeyInfo getOriginatorKeyInfo(); 81 82 /** 83 * Set the child element containing the key generation material for the originator. 84 * 85 * @param newOriginatorKeyInfo the new OriginatorKeyInfo child element 86 */ 87 public void setOriginatorKeyInfo(OriginatorKeyInfo newOriginatorKeyInfo); 88 89 /** 90 * Get the child element containing the key generation material for the recipient. 91 * 92 * @return the RecipientKeyInfo child element 93 */ 94 public RecipientKeyInfo getRecipientKeyInfo(); 95 96 /** 97 * Set the child element containing the key generation material for the recipient. 98 * 99 * @param newRecipientKeyInfo the new RecipientKeyInfo child element 100 */ 101 public void setRecipientKeyInfo(RecipientKeyInfo newRecipientKeyInfo); 102 103 }