pub fn body(self) -> Vec<u8> {
        let new_crate = u::EncodableCrateUpload {
            name: u::EncodableCrateName(self.krate_name.clone()),
            vers: u::EncodableCrateVersion(self.version),
            features: HashMap::new(),
            deps: self.deps,
            authors: self.authors,
            description: self.desc,
            homepage: None,
            documentation: self.doc_url,
            readme: self.readme,
            readme_file: None,
            keywords: u::EncodableKeywordList(
                self.keywords.into_iter().map(u::EncodableKeyword).collect(),
            ),
            categories: u::EncodableCategoryList(
                self.categories
                    .into_iter()
                    .map(u::EncodableCategory)
                    .collect(),
            ),
            license: self.license,
            license_file: self.license_file,
            repository: None,
            badges: Some(self.badges),
            links: None,
        };

        let json = serde_json::to_string(&new_crate).unwrap();
        let mut body = Vec::new();
        body.extend(
            [
                json.len() as u8,
                (json.len() >> 8) as u8,
                (json.len() >> 16) as u8,
                (json.len() >> 24) as u8,
            ]
            .iter()
            .cloned(),
        );
        body.extend(json.as_bytes().iter().cloned());

        let tarball = &self.tarball;
        body.extend(&[
            tarball.len() as u8,
            (tarball.len() >> 8) as u8,
            (tarball.len() >> 16) as u8,
            (tarball.len() >> 24) as u8,
        ]);
        body.extend(tarball);
        body
    }
/// Consume this builder to make the Put request body
Consume this builder to make the Put request body
Consume this builder to make the Put request body
pub fn body(self) -> Vec<u8> {
        let new_crate = u::EncodableCrateUpload {
            name: u::EncodableCrateName(self.krate_name.clone()),
            vers: u::EncodableCrateVersion(self.version),
            features: HashMap::new(),
            deps: self.deps,
            authors: self.authors,
            description: self.desc,
            homepage: None,
            documentation: self.doc_url,
            readme: self.readme,
            readme_file: None,
            keywords: u::EncodableKeywordList(
                self.keywords.into_iter().map(u::EncodableKeyword).collect(),
            ),
            categories: u::EncodableCategoryList(
                self.categories
                    .into_iter()
                    .map(u::EncodableCategory)
                    .collect(),
            ),
            license: self.license,
            license_file: self.license_file,
            repository: None,
            badges: Some(self.badges),
            links: None,
        };
        let json = serde_json::to_string(&new_crate).unwrap();
        let mut body = Vec::new();
        body.extend(
            [
                json.len() as u8,
                (json.len() >> 8) as u8,
                (json.len() >> 16) as u8,
                (json.len() >> 24) as u8,
            ]
            .iter()
            .cloned(),
        );
        body.extend(json.as_bytes().iter().cloned());
        let tarball = &self.tarball;
        body.extend(&[
            tarball.len() as u8,
            (tarball.len() >> 8) as u8,
            (tarball.len() >> 16) as u8,
            (tarball.len() >> 24) as u8,
        ]);
        body.extend(tarball);
        body
    }
pub fn body ( self ) -> Vec < u8 > { let new_crate = u :: EncodableCrateUpload { name : u :: EncodableCrateName ( self . krate_name . clone ( ) ) , vers : u :: EncodableCrateVersion ( self . version ) , features : HashMap :: new ( ) , deps : self . deps , authors : self . authors , description : self . desc , homepage : None , documentation : self . doc_url , readme : self . readme , readme_file : None , keywords : u :: EncodableKeywordList ( self . keywords . into_iter ( ) . map ( u :: EncodableKeyword ) . collect ( ) , ) , categories : u :: EncodableCategoryList ( self . categories . into_iter ( ) . map ( u :: EncodableCategory ) . collect ( ) , ) , license : self . license , license_file : self . license_file , repository : None , badges : Some ( self . badges ) , links : None , } ; let json = serde_json :: to_string ( & new_crate ) . unwrap ( ) ; let mut body = Vec :: new ( ) ; body . extend ( [ json . len ( ) as u8 , ( json . len ( ) >> 8 ) as u8 , ( json . len ( ) >> 16 ) as u8 , ( json . len ( ) >> 24 ) as u8 , ] . iter ( ) . cloned ( ) , ) ; body . extend ( json . as_bytes ( ) . iter ( ) . cloned ( ) ) ; let tarball = & self . tarball ; body . extend ( & [ tarball . len ( ) as u8 , ( tarball . len ( ) >> 8 ) as u8 , ( tarball . len ( ) >> 16 ) as u8 , ( tarball . len ( ) >> 24 ) as u8 , ] ) ; body . extend ( tarball ) ; body }
Consume this builder to make the Put request body
Consume this builder to make the Put request body
self