github.com/vc42/parquet-go@v0.0.0-20240320194221-1a9adb5f23f5/parquet.go (about)

     1  // Copyright 2022 Twilio Inc.
     2  
     3  // Package parquet is a library for working with parquet files. For an overview
     4  // of Parquet's qualities as a storage format, see this blog post:
     5  // https://blog.twitter.com/engineering/en_us/a/2013/dremel-made-simple-with-parquet
     6  //
     7  // Or see the Parquet documentation: https://parquet.apache.org/docs/
     8  package parquet
     9  
    10  func atLeastOne(size int) int {
    11  	return atLeast(size, 1)
    12  }
    13  
    14  func atLeast(size, least int) int {
    15  	if size < least {
    16  		return least
    17  	}
    18  	return size
    19  }
    20  
    21  func min(a, b int) int {
    22  	if a < b {
    23  		return a
    24  	}
    25  	return b
    26  }
    27  
    28  func max(a, b int) int {
    29  	if a > b {
    30  		return a
    31  	}
    32  	return b
    33  }