Inline rgp module

This commit is contained in:
Dirkjan Ochtman 2021-12-07 10:59:51 +01:00 committed by masalachai
parent 6d1c749b67
commit b5b17e5b3f
4 changed files with 10 additions and 11 deletions

View File

@ -1,6 +0,0 @@
//! Types for EPP RGP restore requests
pub mod report;
pub mod request;
pub const EPP_DOMAIN_RGP_EXT_XMLNS: &str = "urn:ietf:params:xml:ns:rgp-1.0";

View File

@ -7,7 +7,7 @@ use crate::request::EppExtension;
use chrono::{DateTime, SecondsFormat, Utc};
use serde::{Deserialize, Serialize};
use super::EPP_DOMAIN_RGP_EXT_XMLNS;
use super::XMLNS;
/// Type that represents the domain rgp restore report extension
///
@ -99,7 +99,7 @@ impl RgpRestoreReport {
let statements = statements.iter().map(|&s| s.into()).collect();
RgpRestoreReport {
xmlns: EPP_DOMAIN_RGP_EXT_XMLNS.to_string(),
xmlns: XMLNS.to_string(),
restore: RgpRestoreReportSection {
op: "report".to_string(),
report: RgpRestoreReportSectionData {

View File

@ -8,7 +8,7 @@ use crate::request::EppExtension;
use serde::{Deserialize, Serialize};
use super::EPP_DOMAIN_RGP_EXT_XMLNS;
use super::XMLNS;
/// Type that represents the <epp> request for a domain rgp restore request command
///
@ -67,7 +67,7 @@ impl RgpRestoreRequest {
/// Creates a new instance of EppDomainRgpRestoreRequest
pub fn new() -> RgpRestoreRequest {
RgpRestoreRequest {
xmlns: EPP_DOMAIN_RGP_EXT_XMLNS.to_string(),
xmlns: XMLNS.to_string(),
restore: RgpRestoreRequestData {
op: "request".to_string(),
},

View File

@ -138,7 +138,12 @@ pub mod domain {
pub mod extensions {
pub mod consolidate;
pub mod namestore;
pub mod rgp;
pub mod rgp {
pub mod report;
pub mod request;
pub const XMLNS: &str = "urn:ietf:params:xml:ns:rgp-1.0";
}
}
pub mod host {