Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 16 for MarshalXML (0.17 sec)

  1. internal/bucket/lifecycle/transition.go

    		return errTransitionDateNotMidnight
    	}
    
    	*tDate = TransitionDate{trnDate}
    	return nil
    }
    
    // MarshalXML encodes expiration date if it is non-zero and encodes
    // empty string otherwise
    func (tDate TransitionDate) MarshalXML(e *xml.Encoder, startElement xml.StartElement) error {
    	if tDate.Time.IsZero() {
    		return nil
    	}
    	return e.EncodeElement(tDate.Format(time.RFC3339), startElement)
    Go
    - Registered: Sun Apr 21 19:28:08 GMT 2024
    - Last Modified: Mon Jan 10 17:07:49 GMT 2022
    - 5.1K bytes
    - Viewed (0)
  2. internal/bucket/lifecycle/expiration.go

    		return err
    	}
    	if numDays <= 0 {
    		return errLifecycleInvalidDays
    	}
    	*eDays = ExpirationDays(numDays)
    	return nil
    }
    
    // MarshalXML encodes number of days to expire if it is non-zero and
    // encodes empty string otherwise
    func (eDays ExpirationDays) MarshalXML(e *xml.Encoder, startElement xml.StartElement) error {
    	if eDays == 0 {
    		return nil
    	}
    	return e.EncodeElement(int(eDays), startElement)
    }
    
    Go
    - Registered: Sun Apr 21 19:28:08 GMT 2024
    - Last Modified: Wed Feb 21 20:28:34 GMT 2024
    - 6.6K bytes
    - Viewed (1)
  3. internal/bucket/lifecycle/noncurrentversion.go

    	NewerNoncurrentVersions int            `xml:"NewerNoncurrentVersions,omitempty"`
    	set                     bool
    }
    
    // MarshalXML if non-current days not set to non zero value
    func (n NoncurrentVersionExpiration) MarshalXML(e *xml.Encoder, start xml.StartElement) error {
    	if n.IsNull() {
    		return nil
    	}
    	type noncurrentVersionExpirationWrapper NoncurrentVersionExpiration
    Go
    - Registered: Sun Apr 21 19:28:08 GMT 2024
    - Last Modified: Tue Dec 14 17:41:44 GMT 2021
    - 5.3K bytes
    - Viewed (1)
  4. internal/event/arn.go

    	if arn.TargetID.ID == "" && arn.TargetID.Name == "" && arn.region == "" {
    		return ""
    	}
    
    	return "arn:minio:sqs:" + arn.region + ":" + arn.TargetID.String()
    }
    
    // MarshalXML - encodes to XML data.
    func (arn ARN) MarshalXML(e *xml.Encoder, start xml.StartElement) error {
    	return e.EncodeElement(arn.String(), start)
    }
    
    // UnmarshalXML - decodes XML data.
    Go
    - Registered: Sun Apr 21 19:28:08 GMT 2024
    - Last Modified: Tue Jun 01 21:59:40 GMT 2021
    - 2.1K bytes
    - Viewed (0)
  5. internal/bucket/lifecycle/prefix.go

    	var s string
    	if err = d.DecodeElement(&s, &start); err != nil {
    		return err
    	}
    	*p = Prefix{string: s, set: true}
    	return nil
    }
    
    // MarshalXML - decodes XML data.
    func (p Prefix) MarshalXML(e *xml.Encoder, startElement xml.StartElement) error {
    	if !p.set {
    		return nil
    	}
    	return e.EncodeElement(p.string, startElement)
    }
    
    // String returns the prefix string
    Go
    - Registered: Sun Apr 21 19:28:08 GMT 2024
    - Last Modified: Tue Aug 15 14:45:25 GMT 2023
    - 1.5K bytes
    - Viewed (0)
  6. internal/bucket/replication/sourceselectioncriteria.go

    		return err
    	}
    	if len(ssc.ReplicaModifications.Status) == 0 {
    		ssc.ReplicaModifications.Status = Enabled
    	}
    	*s = SourceSelectionCriteria(ssc)
    	return nil
    }
    
    // MarshalXML - encodes to XML data.
    func (s SourceSelectionCriteria) MarshalXML(e *xml.Encoder, start xml.StartElement) error {
    	if err := e.EncodeToken(start); err != nil {
    		return err
    	}
    	if s.IsValid() {
    Go
    - Registered: Sun Apr 21 19:28:08 GMT 2024
    - Last Modified: Tue Jun 01 21:59:40 GMT 2021
    - 2.5K bytes
    - Viewed (0)
  7. cmd/api-datatypes.go

    }
    
    // DeleteMarkerMTime is an embedded type containing time.Time for XML marshal
    type DeleteMarkerMTime struct {
    	time.Time
    }
    
    // MarshalXML encodes expiration date if it is non-zero and encodes
    // empty string otherwise
    func (t DeleteMarkerMTime) MarshalXML(e *xml.Encoder, startElement xml.StartElement) error {
    	if t.Time.IsZero() {
    		return nil
    	}
    	return e.EncodeElement(t.Time.Format(time.RFC3339), startElement)
    Go
    - Registered: Sun Apr 21 19:28:08 GMT 2024
    - Last Modified: Mon Jan 03 09:28:52 GMT 2022
    - 3K bytes
    - Viewed (0)
  8. internal/event/config.go

    	Name  string `xml:"Name"`
    	Value string `xml:"Value"`
    }
    
    func (filter FilterRule) isEmpty() bool {
    	return filter.Name == "" && filter.Value == ""
    }
    
    // MarshalXML implements a custom marshaller to support `omitempty` feature.
    func (filter FilterRule) MarshalXML(e *xml.Encoder, start xml.StartElement) error {
    	if filter.isEmpty() {
    		return nil
    	}
    	type filterRuleWrapper FilterRule
    Go
    - Registered: Sun Apr 21 19:28:08 GMT 2024
    - Last Modified: Tue Nov 16 17:28:29 GMT 2021
    - 8.4K bytes
    - Viewed (0)
  9. internal/bucket/replication/destination.go

    // used for multi-destination targets
    func (d Destination) TargetArn() bool {
    	return strings.HasPrefix(d.ARN, DestinationARNMinIOPrefix)
    }
    
    // MarshalXML - encodes to XML data.
    func (d Destination) MarshalXML(e *xml.Encoder, start xml.StartElement) error {
    	if err := e.EncodeToken(start); err != nil {
    		return err
    	}
    Go
    - Registered: Sun Apr 21 19:28:08 GMT 2024
    - Last Modified: Mon Sep 04 19:57:37 GMT 2023
    - 4K bytes
    - Viewed (2)
  10. internal/bucket/lifecycle/filter.go

    	And    And
    	andSet bool
    
    	Tag    Tag
    	tagSet bool
    
    	// Caching tags, only once
    	cachedTags map[string]string
    }
    
    // MarshalXML - produces the xml representation of the Filter struct
    // only one of Prefix, And and Tag should be present in the output.
    func (f Filter) MarshalXML(e *xml.Encoder, start xml.StartElement) error {
    	if err := e.EncodeToken(start); err != nil {
    		return err
    	}
    
    	switch {
    Go
    - Registered: Sun Apr 21 19:28:08 GMT 2024
    - Last Modified: Tue Feb 27 00:01:20 GMT 2024
    - 6.2K bytes
    - Viewed (0)
Back to top