repo_name
stringlengths
6
101
path
stringlengths
4
300
text
stringlengths
7
1.31M
avlyalin/github-actions-test
src/containers/game/game.stories.js
import React from 'react'; import { withKnobs, radios } from '@storybook/addon-knobs'; import { BrowserRouter } from 'react-router-dom'; import { Route } from 'react-router-dom'; import { containerDecorator } from '_storybook/container'; import { TEAMS } from 'src/data/constants'; import { with_opened_cards_5x5 } from 'src/data/fixtures'; import { Game } from './game'; // eslint-disable-next-line import/no-default-export export default { title: 'Containers/Game', decorators: [ containerDecorator({ styles: { padding: 0 }, }), withKnobs, ], }; export const Common = () => { const color = radios( 'User team', { default: 'default', blue: 'blue', red: 'red' }, 'blue', ); const winnerTeam = radios( 'Winner team', { 'no winner': '', blue: 'blue', red: 'red' }, '', ); const captains = { [TEAMS['blue']]: '1', [TEAMS['red']]: '2', }; const user = { id: '0', name: 'Killer 3000', team: color, }; return ( <BrowserRouter> <Route> <Game cards={with_opened_cards_5x5} captains={captains} currentUser={user} winnerTeam={winnerTeam} onOpenCard={() => {}} /> </Route> </BrowserRouter> ); };
mb3rn4l/reserva-canchas-hexagonal
microservicio/dominio/src/main/java/com/ceiba/tipocancha/modelo/dto/DtoTipoCancha.java
package com.ceiba.tipocancha.modelo.dto; import lombok.AllArgsConstructor; import lombok.Getter; @Getter @AllArgsConstructor public class DtoTipoCancha { private Long id; private String tipo; private double valorCancha; }
LazyFalcon/TechDemo-v4
src/Common/PerfTimers.hpp
<filename>src/Common/PerfTimers.hpp #pragma once #include <queue> #include "Timer.hpp" typedef u64 timeType; struct TimeRecord // in 1e-6s { timeType last {0}; timeType max {0}; timeType total {0}; timeType captured {0}; u64 count {0}; void update(timeType dt); }; class CpuTimerScoped { public: CpuTimerScoped(const std::string& name); CpuTimerScoped(const std::string& name, i32 line); ~CpuTimerScoped(); void between(i32 line); static std::map<std::string, TimeRecord> cpuRecords; static void writeToFile(); static bool printRecords; static bool saveRecords; private: const std::string name; Timer<timeType, 1'000'000, 1> timer; }; #define CPU_SCOPE_TIMER(name) CpuTimerScoped _scopeTimer(name); #define CPU_SCOPE_TIMER_UNNAMED() CpuTimerScoped _scopeTimer(__PRETTY_FUNCTION__); class GpuTimerScoped { public: GpuTimerScoped(const std::string& name); ~GpuTimerScoped(); static void init(); static void print(); static void writeToFile(); static std::map<std::string, std::pair<u32, TimeRecord>> gpuRecords; private: static std::queue<u32> freeTimerIds; }; #define GPU_SCOPE_TIMER() GpuTimerScoped _gpuScopeTimer(__FUNCTION__);
talentdeveloper511/Sprout
App/Services/Queries/TPT.js
<filename>App/Services/Queries/TPT.js<gh_stars>0 /* eslint-disable no-trailing-spaces,new-cap */ /** * Created by viktor on 9/8/17. */ // ======================================================== // Import Packages // ======================================================== import {AsyncStorage} from 'react-native' import gql from 'graphql-tag' import {tptClient, fundingClient, transferClient} from '../../Config/AppConfig' import {USER_ENTITIES} from '../../Utility/Mapper/User' import {CHILD_ENTITIES} from '../../Utility/Mapper/Child' import {AUTH_ENTITIES} from '../../Utility/Mapper/Auth' import {GOAL_ENTITIES} from '../../Utility/Mapper/Goal' import {convertDateToRequestFormat} from '../../Utility/Transforms/Converter' // ======================================================== // Queries // ======================================================== export const foo = () => { let foo = (residencyType, familyBrokerageFlag, familyPoliticalFlag, stockOwnerFlag) => { // switch (residencyType) { // case USER_ENTITIES.CITIZEN: { // // } // break // case USER_ENTITIES.GREENCARD: { // // } // break // case USER_ENTITIES.VISA: { // if // } // break // } return gql` mutation ($clientID: String!, $userID: String!, $childID: String!, $incomeRange: String!, $assetsWorth: String!, $investorType: String!, $firstName: String!, $lastName: String!, $emailID: String!, $DOB: String!, $ssn: String!, $citizenshipCountry: String!, $birthCountry: String!, $phone: String!, $employmentStatus: String!, $line1: String!, $line2: String!, $city: String!, $state: String!, $postalCode: String!, $disclosureType: String!, $disclosurePoliticalExposureOrganization: String, $disclosurePoliticalExposureFamily: [String], $disclosureControlPersonCompanySymbols: [String], $disclosureFirmAffiliationName: String, $visaType: String, $visaExpiration: String, $childFirstName: String!, $childLastName: String!, $childSSN: String!, $childDOB: String!){ createAccount (input: { client_id: $clientID, user_id: $userID, sprout_id: $childID, income_range: $incomeRange, assets_worth: $assetsWorth, investor_type: $investorType, applicants: [ { applicant_type: "custodian", first: $firstName, middle: "Demo" last: $lastName, email: $emailID, birthday: $DOB, ssn: $ssn, citizenship_country: $citizenshipCountry, birth_country: $birthCountry, mobile: $phone, employment_status: $employmentStatus, line_1: $line1, line_2: $line2, city: $city, state: $state, postal_code: $postalCode, disclosure_type: $disclosureType, disclosure_political_exposure_organization: $disclosurePoliticalExposureOrganization, disclosure_political_exposure_family: $disclosurePoliticalExposureFamily, disclosure_control_person_company_symbols: $disclosureControlPersonCompanySymbols, disclosure_firm_affiliation_name: $disclosureFirmAffiliationName, visa_type: $visaType, visa_expiration: $visaExpiration }, { applicant_type: "minor", first: $childFirstName, middle: "Demo", last: $childLastName, email: $emailID, birthday: $childDOB, ssn: $childSSN, citizenship_country: $citizenshipCountry, mobile: $phone, employment_status: "student", line_1: $line1, line_2: $line2, city: $city, state: $state, postal_code: $postalCode } ] }) { account_id status } } ` } async function createAccount (userData, childData, userID, childSSN, emailID) { let childDOB = childData['date_of_birth'] let modifiedChildDOB = convertDateToRequestFormat(childDOB) modifiedChildDOB && (childData['date_of_birth'] = modifiedChildDOB) console.log(' ---- now mutating ---- ', userData, childData, userID, '\n childSSN: ', childSSN, '\nemailID : ', emailID) console.log('<<----- running add account --->> :: ') let token = await AsyncStorage.getItem(AUTH_ENTITIES.ID_TOKEN) console.log('g-t add account token now') let mutation = foo() let ql = new tptClient(token).client return ql.mutate( { mutation, variables: { clientID: '11-11-11', userID: userID, incomeRange: userData[USER_ENTITIES.SALARY_PER_YEAR], assetsWorth: userData[USER_ENTITIES.USER_TOTAL_VALUE], investorType: userData[USER_ENTITIES.INVESTOR_TYPE], firstName: userData[USER_ENTITIES.FIRST_NAME], lastName: userData[USER_ENTITIES.LAST_NAME], emailID: emailID, DOB: userData[USER_ENTITIES.DOB], ssn: userData[USER_ENTITIES.SSN], citizenshipCountry: userData[USER_ENTITIES.COUNTRY_CITIZENSHIP] || 'USA', birthCountry: userData[USER_ENTITIES.COUNTRY_BORN] || 'USA', // optional phone: userData[USER_ENTITIES.PHONE_NUMBER], employmentStatus: userData[USER_ENTITIES.EMPLOYMENT_TYPE], line1: userData[USER_ENTITIES.ADDRESS_LINE_1], line2: userData[USER_ENTITIES.ADDRESS_LINE_2] || 'null', // optional city: userData[USER_ENTITIES.CITY], state: userData[USER_ENTITIES.STATE], postalCode: userData[USER_ENTITIES.ZIP_CODE], disclosureType: [userData[USER_ENTITIES.FAMILY_POLITICAL_FLAG] ? 'political_exposure' : '', userData[USER_ENTITIES.FAMILY_BROKERAGE_FLAG] ? 'control_person' : '', userData[USER_ENTITIES.STOCK_OWNER_FLAG] ? 'firm_affiliation' : ''], // optional disclosurePoliticalExposureOrganization: userData[USER_ENTITIES.FAMILY_POLITICAL_FLAG] ? userData[USER_ENTITIES.POLITICAL_ORGANISATION] : undefined, // optional disclosurePoliticalExposureFamily: userData[USER_ENTITIES.FAMILY_POLITICAL_FLAG] ? userData[USER_ENTITIES.POLITICAL_ASSOCIATED_RELATIVE] : undefined, // optional disclosureControlPersonCompanySymbols: userData[USER_ENTITIES.FAMILY_BROKERAGE_FLAG] ? userData[USER_ENTITIES.STOCK_TICKER] : undefined, // optional disclosureFirmAffiliationName: userData[USER_ENTITIES.STOCK_OWNER_FLAG] ? userData[USER_ENTITIES.STOCK_BROKERAGE_FIRM] : undefined, // optional visaType: userData[USER_ENTITIES.VISA_TYPE] || undefined, // optional visaExpiration: userData[USER_ENTITIES.VISA_EXPIRY] || undefined, // optional // child values childID: childData['sprout_id'], childFirstName: childData['first_name'], childLastName: childData['last_name'], childSSN: childSSN || userData[USER_ENTITIES.SSN], // childDOB: childData['date_of_birth'] } }) } return { createAccount } } export const createChildAccount = () => { let foo = (ssn) => { if (ssn) { return gql` mutation ($clientID: String!, $userID: String!, $childID: String!, $childFirstName: String!, $childLastName: String!, $childDOB: String!, $childSSN: String!){ createChildAccount (input: { client_id: $clientID, user_id: $userID, sprout_id: $childID, first: $childFirstName, last: $childLastName, birthday: $childDOB, child_ssn: $childSSN }) { account_id status } } ` } else { return gql` mutation ($clientID: String!, $userID: String!, $childID: String!, $childFirstName: String!, $childLastName: String!, $childDOB: String!){ createChildAccount (input: { client_id: $clientID, user_id: $userID, sprout_id: $childID, first: $childFirstName, last: $childLastName, birthday: $childDOB }) { account_id status } } ` } } async function createChildAccount (childData, userID, childSSN) { let childDOB = childData['date_of_birth'] let modifiedChildDOB = convertDateToRequestFormat(childDOB) modifiedChildDOB && (childData['date_of_birth'] = modifiedChildDOB) console.log(' ---- now mutating for child account ---- ', childData, userID, '\n childSSN: ', childSSN) console.log('<<----- running add account --->> :: ') let token = await AsyncStorage.getItem(AUTH_ENTITIES.ID_TOKEN) console.log('g-t add account token now') let ql = new tptClient(token).client let mutation = foo(childSSN) return ql.mutate( { mutation, variables: { clientID: '11-11-11', userID: userID, childID: childData['sprout_id'], childFirstName: childData['first_name'], childLastName: childData['last_name'], childSSN: childSSN, childDOB: childData['date_of_birth'] } }) } return { createChildAccount } } export const linkPlaidQuery = () => { let mutation = gql` mutation ($userID: String!, $plaidPublicToken: String!, $plaidAccountID: String!) { createFundingSource(input: { user_id: $userID, plaid_public_token: $plaidPublicToken, plaid_account_id: $plaidAccountID }) { source_reference_id status } } ` async function linkPlaid (userData) { console.log('<<----- running link plaid --->> :: ,', userData) let token = await AsyncStorage.getItem(AUTH_ENTITIES.ID_TOKEN) console.log('got link plaid token now') let ql = new fundingClient(token).client return ql.mutate({ mutation, variables: { userID: userData[USER_ENTITIES.USER_ID], plaidPublicToken: userData[USER_ENTITIES.PLAID_PUBLIC_TOKEN], plaidAccountID: userData[USER_ENTITIES.PLAID_ACCOUNT_ID] } } ) } return { linkPlaid } } export const initiateTransfer = () => { let mutation = gql` mutation ($userID: String!, $childID: String!, $goalID: String!, $amount: String!, $frequency: String!) { createTransfer(input: { user_id: $userID, sprout_id: $childID, goal_id: $goalID, amount: $amount, frequency: $frequency }) { transfer_id status } } ` async function doTransfer (data) { console.log('<<----- running transfer --->> :: ', data) let token = await AsyncStorage.getItem(AUTH_ENTITIES.ID_TOKEN) console.log('g-t transfer token now') let ql = new transferClient(token).client return ql.mutate({ mutation, variables: { userID: data[USER_ENTITIES.USER_ID], childID: data[CHILD_ENTITIES.CHILD_ID], goalID: data[GOAL_ENTITIES.GID], amount: data[GOAL_ENTITIES.TRANSFER_AMOUNT], frequency: data[GOAL_ENTITIES.RECURRING_FREQUENCY] } }) } return { doTransfer } }
duncangrant/incubator-brooklyn
core/src/test/java/brooklyn/test/entity/TestClusterImpl.java
/* * Licensed to the Apache Software Foundation (ASF) under one * or more contributor license agreements. See the NOTICE file * distributed with this work for additional information * regarding copyright ownership. The ASF licenses this file * to you under the Apache License, Version 2.0 (the * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY * KIND, either express or implied. See the License for the * specific language governing permissions and limitations * under the License. */ package brooklyn.test.entity; import brooklyn.entity.basic.QuorumCheck.QuorumChecks; import brooklyn.entity.group.DynamicClusterImpl; import brooklyn.entity.trait.Startable; /** * Mock cluster entity for testing. */ public class TestClusterImpl extends DynamicClusterImpl implements TestCluster { private volatile int size; public TestClusterImpl() { } @Override public void init() { super.init(); size = getConfig(INITIAL_SIZE); setAttribute(Startable.SERVICE_UP, true); } @Override protected void initEnrichers() { // say this is up if it has no children setConfig(UP_QUORUM_CHECK, QuorumChecks.atLeastOneUnlessEmpty()); super.initEnrichers(); } @Override public Integer resize(Integer desiredSize) { this.size = desiredSize; return size; } @Override public void stop() { size = 0; super.stop(); } @Override public Integer getCurrentSize() { return size; } }
brianmock/ruby-code-challenges
validEmail.rb
<filename>validEmail.rb ARGV.each do|file| array = Array.new File.open(file).readlines.map do |line| array << line.to_s.gsub(/\n/,"") end #print array array.each {|x| if x == "" nil elsif (x[-4..-1] == "\.com" || x[-4..-1] == "\.org" || x[-4..-1] == "\.edu" || x[-4..-1] == "\.gov") && (x.count("\@") == 1) puts "true" else puts "false" end } end
corneliouzbett/dhis2-android-capture-app
app/src/main/java/org/dhis2/utils/ObjectStyleUtils.java
package org.dhis2.utils; import android.content.Context; import android.content.res.Resources; import android.graphics.Color; import android.graphics.drawable.Drawable; import androidx.annotation.ColorRes; import androidx.appcompat.content.res.AppCompatResources; import androidx.core.content.ContextCompat; import org.dhis2.R; import org.dhis2.utils.resources.ResourceManager; import static android.text.TextUtils.isEmpty; public class ObjectStyleUtils { public static Drawable getIconResource(Context context, String resourceName, int defaultResource) { if (defaultResource == -1) { return null; } Drawable defaultDrawable = AppCompatResources.getDrawable(context, defaultResource); if (!isEmpty(resourceName)) { int iconResource = new ResourceManager(context) .getObjectStyleDrawableResource(resourceName, R.drawable.ic_default_icon); Drawable drawable = AppCompatResources.getDrawable(context, iconResource); if (drawable != null) drawable.mutate(); return drawable != null ? drawable : defaultDrawable; } else return defaultDrawable; } public static int getColorResource(Context context, String styleColor, @ColorRes int defaultColorResource) { if (styleColor == null) { return ContextCompat.getColor(context, defaultColorResource); } else { String color = styleColor.startsWith("#") ? styleColor : "#" + styleColor; int colorRes; if (color.length() == 4) return ContextCompat.getColor(context, defaultColorResource); else colorRes = Color.parseColor(color); return colorRes; } } }
simoexpo/as4k
src/test/scala/org/simoexpo/as4k/KRecordSeqSourceConverterSpec.scala
package org.simoexpo.as4k import akka.stream.scaladsl.{Sink, Source} import org.apache.kafka.clients.consumer.OffsetAndMetadata import org.apache.kafka.common.TopicPartition import org.mockito.Mockito.{reset, verify, when} import org.scalatest.BeforeAndAfterEach import org.scalatest.concurrent.{IntegrationPatience, ScalaFutures} import org.simoexpo.as4k.KSource._ import org.simoexpo.as4k.consumer.KafkaConsumerActor.KafkaCommitException import org.simoexpo.as4k.consumer.KafkaConsumerAgent import org.simoexpo.as4k.producer.KafkaProducerActor.KafkaProduceException import org.simoexpo.as4k.producer.{KafkaSimpleProducerAgent, KafkaTransactionalProducerAgent} import org.simoexpo.as4k.testing.{ActorSystemSpec, BaseSpec, DataHelperSpec} import scala.concurrent.Future class KRecordSeqSourceConverterSpec extends BaseSpec with ScalaFutures with ActorSystemSpec with IntegrationPatience with BeforeAndAfterEach with DataHelperSpec { private val kafkaConsumerAgent: KafkaConsumerAgent[Int, String] = mock[KafkaConsumerAgent[Int, String]] private val kafkaSimpleProducerAgent: KafkaSimpleProducerAgent[Int, String] = mock[KafkaSimpleProducerAgent[Int, String]] private val kafkaTransactionalProducerAgent: KafkaTransactionalProducerAgent[Int, String] = mock[KafkaTransactionalProducerAgent[Int, String]] override def beforeEach(): Unit = reset(kafkaConsumerAgent, kafkaSimpleProducerAgent, kafkaTransactionalProducerAgent) "KRecordSeqSourceConverter" when { val inTopic = "input_topic" val outTopic = "output_topic" val partitions = 3 val records = Range(0, 100).map(n => aKRecord(n, n, s"value$n", inTopic, n % partitions, "defaultGroup")).toList "committing records" should { val callback = (offsets: Map[TopicPartition, OffsetAndMetadata], exception: Option[Exception]) => exception match { case None => println(s"successfully commit offset $offsets") case Some(_) => println(s"fail commit offset $offsets") } "call commit on KafkaConsumerAgent for a list of KRecord" in { when(kafkaConsumerAgent.commitBatch(records, Some(callback))).thenReturn(Future.successful(records)) val recordConsumed = Source.single(records).commit()(kafkaConsumerAgent, Some(callback)).mapConcat(_.toList).runWith(Sink.seq) whenReady(recordConsumed) { _ => verify(kafkaConsumerAgent).commitBatch(records, Some(callback)) } } "fail if kafka consumer fail to commit for a list of KRecord" in { when(kafkaConsumerAgent.commitBatch(records, Some(callback))) .thenReturn(Future.failed(KafkaCommitException(new RuntimeException("Something bad happened!")))) val recordConsumed = Source.single(records).commit()(kafkaConsumerAgent, Some(callback)).mapConcat(_.toList).runWith(Sink.seq) whenReady(recordConsumed.failed) { exception => verify(kafkaConsumerAgent).commitBatch(records, Some(callback)) exception shouldBe a[KafkaCommitException] } } } "producing KRecords on a topic" should { "allow to call produce on KafkaTransactionalProducerAgent for a list of KRecord" in { when(kafkaTransactionalProducerAgent.produce(records, outTopic)).thenReturn(Future.successful(records)) val recordProduced = Source.single(records).produce(outTopic)(kafkaTransactionalProducerAgent).runWith(Sink.seq) whenReady(recordProduced) { _ => verify(kafkaTransactionalProducerAgent).produce(records, outTopic) } } "fail with a KafkaProduceException if KafkaTransactionalProducerAgent fail to produce a list of KRecord" in { when(kafkaTransactionalProducerAgent.produce(records, outTopic)) .thenReturn(Future.failed(KafkaProduceException(new RuntimeException("Something bad happened!")))) val recordProduced = Source.single(records).produce(outTopic)(kafkaTransactionalProducerAgent).runWith(Sink.seq) whenReady(recordProduced.failed) { exception => verify(kafkaTransactionalProducerAgent).produce(records, outTopic) exception shouldBe a[KafkaProduceException] } } } "producing and committing KRecord on a topic" should { "allow to call produceAndCommit on KafkaTransactionalProducerAgent for a list of KRecord" in { when(kafkaTransactionalProducerAgent.produceAndCommit(records, outTopic)).thenReturn(Future.successful(records)) val recordProduced = Source.single(records).produceAndCommit(outTopic)(kafkaTransactionalProducerAgent).runWith(Sink.seq) whenReady(recordProduced) { _ => verify(kafkaTransactionalProducerAgent).produceAndCommit(records, outTopic) } } "fail with a KafkaProduceException if KafkaTransactionalProducerAgent fail to produce and commit in transaction a list of KRecord" in { when(kafkaTransactionalProducerAgent.produceAndCommit(records, outTopic)) .thenReturn(Future.failed(KafkaProduceException(new RuntimeException("Something bad happened!")))) val recordProduced = Source.single(records).produceAndCommit(outTopic)(kafkaTransactionalProducerAgent).runWith(Sink.seq) whenReady(recordProduced.failed) { exception => verify(kafkaTransactionalProducerAgent).produceAndCommit(records, outTopic) exception shouldBe a[KafkaProduceException] } } } } }
SWING1993/YYFinance
youyu/Vendor/dswKit/ViewController/UIViewController+toast.h
<gh_stars>0 // // UIViewController+toast.h // qtyd // // Created by stephendsw on 15/8/21. // Copyright (c) 2015年 qtyd. All rights reserved. // #import <UIKit/UIKit.h> @interface UIViewController (toast) #pragma mark - other - (void)showMeg:(NSString *)meg; - (void)showMeg:(NSString *)meg cancelTitle:(NSString *)str; /** * 显示提示信息 */ - (void)showToast:(NSString *)msg; - (void)showToast:(NSString *)msg duration:(unsigned int)val; - (void)showToast:(NSString *)msg done:(void (^)())blcok; - (void)showToast:(NSString *)msg duration:(unsigned int)val done:(void (^)())blcok; #pragma mark - HUD - (void)showHUD:(NSString *)meg; - (void)showHUD; - (void)hideHUD; - (void)showCustomHUD:(UIView *)view; - (void)hideCustomHUB; @end
Terry-Su/Technology-Laboratory
src/D3/Book_2nd/9.1_Transitions_basis/app.js
<filename>src/D3/Book_2nd/9.1_Transitions_basis/app.js import React, { Component } from "react" import { render } from "react-dom" import * as d3 from "d3" class App extends Component { change( { svg, yScale, h } ) { const dataset = [ 11, 12, 15, 20, 18, 17, 16, 18, 23, 25, 5, 10, 13, 19, 21, 25, 22, 18, 15, 13 ] svg .selectAll( "rect" ) .data( dataset ) .transition() .attr( "y", function( d ) { return h - yScale( d ) } ) .attr( "height", function( d ) { return yScale( d ) } ) .attr( "fill", function( d ) { return "rgb(0, 0, " + Math.round( d * 10 ) + ")" } ) } componentDidMount() { const w = 600 const h = 250 const dataset = [ 5, 10, 13, 19, 21, 25, 22, 18, 15, 13, 11, 12, 15, 20, 18, 17, 16, 18, 23, 25 ] const xScale = d3 .scaleBand() .domain( d3.range( dataset.length ) ) .rangeRound( [ 0, w ] ) .paddingInner( 0.05 ) const yScale = d3 .scaleLinear() .domain( [ 0, d3.max( dataset ) ] ) .range( [ 0, h ] ) const svg = d3 .select( "#app" ) .append( "svg" ) .attr( "width", w ) .attr( "height", h ) svg .selectAll( "rect" ) .data( dataset ) .enter() .append( "rect" ) .attr( "x", function( d, i ) { return xScale( i ) } ) .attr( "y", function( d ) { return h - yScale( d ) } ) .attr( "width", xScale.bandwidth() ) .attr( "height", function( d ) { return yScale( d ) } ) .attr( "fill", function( d ) { return "rgb(0, 0, " + Math.round( d * 10 ) + ")" } ) this.change( { svg, yScale, h } ) } render() { return <div></div> } } render( <App />, document.getElementById( "app" ) )
ribafs/linux
Comandos/catalogcommands/libc/exemplos/teste_lib.c
#include "nova_bib.h" int main(int argc, char *argv[]) { int num; if (argc != 2) { printf("Forneca um numero\n"); return 1; } else num = atoi(argv[1]); printf("\n*** fatorial\n"); int fat = fatorial(num); printf("Fatorial de %d = %d\n", num, fat); printf("\n'*** fibonacci\n"); int fib = fibonacci(num); printf("Soma dos %d primeiros numeros de Fibonacci = %d\n\n", num, fib); }
heristhesiya/OpenJSCAD.org
packages/modeling/src/geometries/poly3/create.js
<filename>packages/modeling/src/geometries/poly3/create.js<gh_stars>1000+ /** * Represents a convex 3D polygon. The vertices used to initialize a polygon must * be coplanar and form a convex shape. The vertices do not have to be `vec3` * instances but they must behave similarly. * @typedef {Object} poly3 * @property {Array} vertices - list of ordered vertices (3D) */ /** * Creates a new 3D polygon with initial values. * * @param {Array} [vertices] - a list of vertices (3D) * @returns {poly3} a new polygon * @alias module:modeling/geometries/poly3.create */ const create = (vertices) => { if (vertices === undefined || vertices.length < 3) { vertices = [] // empty contents } return { vertices: vertices } } module.exports = create
geva/tradier.rb
spec/tradier/profile_spec.rb
require 'spec_helper' describe Tradier::Profile do describe "#name" do it "returns the name when set" do profile = Tradier::Profile.new(:profile => { :name => '<NAME>'}) expect(profile.name).to eq('<NAME>') end it "returns nil when name is not set" do profile = Tradier::Profile.new({}) expect(profile.name).to be_nil end end describe '#accounts' do it "returns the accounts when set" do profile = Tradier::Profile.new(:profile => { :account => [{:account_number => '123456789', :type => 'Cash'}] }) expect(profile.accounts).to be_an Array expect(profile.accounts.first).to be_a Tradier::Account end it "returns nil when accounts is not set" do profile = Tradier::Profile.new({}) expect(profile.accounts).to be_nil end end end
ChannD/chann-machine
ruoyi-forum/src/main/java/com/ruoyi/forum/domain/ForumReport.java
package com.ruoyi.forum.domain; import org.apache.commons.lang3.builder.ToStringBuilder; import org.apache.commons.lang3.builder.ToStringStyle; import com.ruoyi.common.annotation.Excel; import com.ruoyi.common.core.domain.BaseEntity; /** * 举报信息对象 forum_report * * @author ruoyi * @date 2021-03-15 */ public class ForumReport extends BaseEntity { private static final long serialVersionUID = 1L; /** 主键 */ private Long id; /** 模块 */ @Excel(name = "模块") private String module; /** 举报类型 */ @Excel(name = "举报类型") private Integer reportType; /** 被举报目标id */ @Excel(name = "被举报目标id") private String targetId; /** 举报人 */ private String reportYhid; /** 信息 */ private String message; /** 处理标志 */ @Excel(name = "处理标志") private Integer dealFlag; /** 处理时间 */ @Excel(name = "处理时间") private String dealTime; public void setId(Long id) { this.id = id; } public Long getId() { return id; } public void setModule(String module) { this.module = module; } public String getModule() { return module; } public void setReportType(Integer reportType) { this.reportType = reportType; } public Integer getReportType() { return reportType; } public void setTargetId(String targetId) { this.targetId = targetId; } public String getTargetId() { return targetId; } public void setReportYhid(String reportYhid) { this.reportYhid = reportYhid; } public String getReportYhid() { return reportYhid; } public void setMessage(String message) { this.message = message; } public String getMessage() { return message; } public void setDealFlag(Integer dealFlag) { this.dealFlag = dealFlag; } public Integer getDealFlag() { return dealFlag; } public void setDealTime(String dealTime) { this.dealTime = dealTime; } public String getDealTime() { return dealTime; } @Override public String toString() { return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE) .append("id", getId()) .append("module", getModule()) .append("reportType", getReportType()) .append("targetId", getTargetId()) .append("reportYhid", getReportYhid()) .append("message", getMessage()) .append("dealFlag", getDealFlag()) .append("dealTime", getDealTime()) .toString(); } }
wentch/redkale-plugins
src/main/java/org/redkalex/source/pgsql/PgReqExtended.java
<reponame>wentch/redkale-plugins<filename>src/main/java/org/redkalex/source/pgsql/PgReqExtended.java /* * To change this license header, choose License Headers in Project Properties. * To change this template file, choose Tools | Templates * and open the template in the editor. */ package org.redkalex.source.pgsql; import java.io.Serializable; import java.util.Objects; import java.util.concurrent.atomic.*; import org.redkale.convert.json.JsonConvert; import org.redkale.net.client.*; import org.redkale.util.*; /** * * @author zhangjx */ public class PgReqExtended extends PgClientRequest { static final byte[] SYNC_BYTES = new ByteArray(128).putByte('S').putInt(4).getBytes(); static final byte[] EXECUTE_BYTES = new ByteArray(128).putByte('E').putInt(4 + 1 + 4).putByte(0).putInt(0).getBytes(); private static final Object[][] ONE_EMPTY_PARAMS = new Object[][]{new Object[0]}; protected int type; protected int fetchSize; protected String sql; protected PgReqExtendMode mode; protected boolean sendPrepare; protected Attribute[] resultAttrs; protected Attribute[] paramAttrs; protected Object[][] paramValues; protected boolean finds; protected int[] findsCount; public PgReqExtended() { } @Override public String toString() { return getClass().getSimpleName() + "_" + Objects.hashCode(this) + "{sql = '" + sql + "', type = " + getType() + ", mergeCount = " + getMergeCount() + ", paramValues = " + (paramValues != null && paramValues.length > 10 ? ("size " + paramValues.length) : JsonConvert.root().convertTo(paramValues)) + "}"; } @Override public int getType() { return type; } public <T> void prepare(int type, PgReqExtendMode mode, String sql, int fetchSize, final Attribute<T, Serializable>[] resultAttrs, final Attribute<T, Serializable>[] paramAttrs, final Object[]... paramValues) { super.prepare(); this.type = type; this.mode = mode; this.sql = sql; this.fetchSize = fetchSize; this.resultAttrs = resultAttrs; this.paramAttrs = paramAttrs; this.paramValues = paramValues; } @Override //是否能合并 protected boolean canMerge(ClientConnection conn) { if (this.type != REQ_TYPE_EXTEND_QUERY) return false; // && this.mode != PgReqExtendMode.FINDS 暂时屏蔽 if (this.mode != PgReqExtendMode.FIND && this.mode != PgReqExtendMode.LIST_ALL) return false; //只支持find sql和list all AtomicBoolean prepared = ((PgClientConnection) conn).getPrepareFlag(sql); return prepared.get(); } @Override //合并成功了返回true protected boolean merge(ClientConnection conn, ClientRequest other) { PgClientRequest req = (PgClientRequest) other; if (this.workThread != req.getWorkThread()) return false; if (req.getType() != REQ_TYPE_EXTEND_QUERY) return false; PgReqExtended extreq = (PgReqExtended) req; if (this.mode != extreq.mode) return false; if (this.paramValues != null && this.paramValues.length > 256) return false; if (extreq.mode != PgReqExtendMode.FIND && extreq.mode != PgReqExtendMode.FINDS && extreq.mode != PgReqExtendMode.LIST_ALL) return false; //只支持find sql和list all if (!this.sql.equals(extreq.sql)) return false; if (mode == PgReqExtendMode.FINDS) { if (paramValues.length + extreq.paramValues.length > 100) return false; if (findsCount == null) findsCount = new int[]{paramValues.length}; this.findsCount = Utility.append(findsCount, extreq.paramValues.length); } this.paramValues = Utility.append(paramValues == null || paramValues.length == 0 ? ONE_EMPTY_PARAMS : paramValues, extreq.paramValues == null || extreq.paramValues.length == 0 ? ONE_EMPTY_PARAMS : extreq.paramValues); return true; } private void writeParse(ByteArray array, Long statementIndex) { // PARSE array.putByte('P'); int start = array.length(); array.putInt(0); if (statementIndex == null) { array.putByte(0); // unnamed prepared statement } else { array.putLong(statementIndex); } writeUTF8String(array, sql); array.putShort(0); // no parameter types array.putInt(start, array.length() - start); } private void writeDescribe(ByteArray array, Long statementIndex) { // DESCRIBE array.putByte('D'); array.putInt(4 + 1 + (statementIndex == null ? 1 : 8)); if (statementIndex == null) { array.putByte('S'); array.putByte(0); } else { array.putByte('S'); array.putLong(statementIndex); } } private void writeBind(ByteArray array, Long statementIndex) { // BIND if (paramValues != null && paramValues.length > 0) { for (Object[] params : paramValues) { { // BIND array.putByte('B'); int start = array.length(); array.putInt(0); array.putByte(0); // portal if (statementIndex == null) { array.putByte(0); // prepared statement } else { array.putLong(statementIndex); } int size = params == null ? 0 : params.length; // number of format codes // 后面跟着的参数格式代码的数目(在下面的 C 中说明)。这个数值可以是零,表示没有参数,或者是参数都使用缺省格式(文本) if (size == 0 || paramAttrs == null) { array.putShort(0); //参数全部为文本格式 } else { array.putShort(0); } // number of parameters //number of format codes 参数格式代码。目前每个都必须是0(文本)或者1(二进制)。 if (size == 0) { array.putShort(0); //结果全部为文本格式 } else { array.putShort(size); int i = -1; for (Object param : params) { PgsqlFormatter.encodePrepareParamValue(array, info, false, paramAttrs == null ? null : paramAttrs[++i], param); } } if (type == REQ_TYPE_EXTEND_QUERY && resultAttrs != null) { //Text format // Result columns are all in Binary format array.putShort(1); array.putShort(1); } else { array.putShort(0); } array.putInt(start, array.length() - start); } { // EXECUTE if (fetchSize == 0) { array.put(EXECUTE_BYTES); } else { array.putByte('E'); array.putInt(4 + 1 + 4); array.putByte(0); //portal 要执行的入口的名字(空字符串选定未命名的入口)。 array.putInt(fetchSize); //要返回的最大行数,如果入口包含返回行的查询(否则忽略)。零标识"没有限制"。 } } } } else { { // BIND array.putByte('B'); int start = array.length(); array.putInt(0); array.putByte(0); // portal if (statementIndex == null) { array.putByte(0); // prepared statement } else { array.putLong(statementIndex); } array.putShort(0); // 后面跟着的参数格式代码的数目(在下面的 C 中说明)。这个数值可以是零,表示没有参数,或者是参数都使用缺省格式(文本) array.putShort(0); //number of format codes 参数格式代码。目前每个都必须是0(文本)或者1(二进制)。 if (type == REQ_TYPE_EXTEND_QUERY && resultAttrs != null) { //Text format // Result columns are all in Binary format array.putShort(1); array.putShort(1); } else { array.putShort(0); } array.putInt(start, array.length() - start); } { // EXECUTE if (fetchSize == 0) { array.put(EXECUTE_BYTES); } else { array.putByte('E'); array.putInt(4 + 1 + 4); array.putByte(0); //portal 要执行的入口的名字(空字符串选定未命名的入口)。 array.putInt(fetchSize); //要返回的最大行数,如果入口包含返回行的查询(否则忽略)。零标识"没有限制"。 } } } } private void writeSync(ByteArray array) { // SYNC array.put(SYNC_BYTES); } @Override public void accept(ClientConnection conn, ByteArray array) { PgClientConnection pgconn = (PgClientConnection) conn; AtomicBoolean prepared = pgconn.getPrepareFlag(sql); if (prepared.get()) { this.sendPrepare = false; writeBind(array, pgconn.getStatementIndex(sql)); writeSync(array); } else { Long statementIndex = pgconn.createStatementIndex(sql); prepared.set(true); this.sendPrepare = true; writeParse(array, statementIndex); writeDescribe(array, statementIndex); //绑定参数 writeBind(array, statementIndex); writeSync(array); } } public static enum PgReqExtendMode { FIND, FINDS, LIST_ALL, OTHER; } }
DDTH/DASP
servlet/src/ddth/dasp/common/api/IApiGroupHandler.java
package ddth.dasp.common.api; public interface IApiGroupHandler { /** * Handles an API call. * * @param apiName * @param params * @param authKey * @param remoteAddr * @return * @throws ApiException */ public Object handleApiCall(String apiName, Object params, String authKey, String remoteAddr) throws ApiException; }
gurfinkel/codeSignal
tournaments/commonPoints/commonPoints.js
function commonPoints(l1, r1, l2, r2) { return Math.max(Math.min(r1, r2) - Math.max(l1, l2) - 1, 0); }
JinshanMa/fenhuo-renren
src/main/java/io/renren/modules/fenhuo/dao/FenhuoRoleDao.java
<reponame>JinshanMa/fenhuo-renren<filename>src/main/java/io/renren/modules/fenhuo/dao/FenhuoRoleDao.java<gh_stars>0 package io.renren.modules.fenhuo.dao; import io.renren.modules.fenhuo.entity.FenhuoRoleEntity; import com.baomidou.mybatisplus.core.mapper.BaseMapper; import org.apache.ibatis.annotations.Mapper; /** * 角色表 * * @author majinshan * @email <EMAIL> * @date 2020-04-30 09:15:45 */ @Mapper public interface FenhuoRoleDao extends BaseMapper<FenhuoRoleEntity> { }
alexxlzhou/scone-core
src/sconelib/scone/measures/Measure.h
/* ** Measure.h ** ** Copyright (C) 2013-2019 <NAME> and contributors. All rights reserved. ** ** This file is part of SCONE. For more information, see http://scone.software. */ #pragma once #include "scone/controllers/Controller.h" #include "scone/core/HasName.h" namespace scone { /// Base class for Measures. class SCONE_API Measure : public Controller { public: Measure( const PropNode& props, Params& par, const Model& model, const Location& loc ); virtual ~Measure() = default; /// Name of the Measure, to be used in reporting; defaults to measure type mutable String name; /// Weighting factor applied to the result of the measure; default = 1. Real weight; /// Threshold above / below which the measure becomes zero; default = 0. Real threshold; /// Transition range above ''threshold'' between which the measure linearly decreases to zero; default = 0. Real threshold_transition; /// Offset added to measure result; default = 0. Real result_offset; /// Indicate whether this measure should be minimized; default value depends on the measure type (usually true). bool minimize; double GetResult( const Model& model ); double GetWeightedResult( const Model& model ); PropNode& GetReport() { return report; } const PropNode& GetReport() const { return report; } virtual const String& GetName() const override; Real GetWeight() { return weight; } Real GetThreshold() { return threshold; } Real GetOffset() { return result_offset; } bool GetMinimize() { return minimize; } protected: virtual double ComputeResult( const Model& model ) = 0; virtual bool ComputeControls( Model& model, double timestamp ) override final { return false; } virtual bool PerformAnalysis( const Model& model, double timestamp ) override final; virtual bool UpdateMeasure( const Model& model, double timestamp ) = 0; double WorstResult() const; PropNode report; xo::optional< double > result; // caches result so it's only computed once }; }
brandontrabucco/ros-image-captioner
src/image_caption_machine/navigator/helper.py
<filename>src/image_caption_machine/navigator/helper.py """Author: <NAME>. Adapted from <NAME>/shmoo_echo/nodes/nav_patch.py """ import tf2_ros import tf2_geometry_msgs import rospy from std_msgs.msg import Bool from flat_ball.msg import TrajWithBackup from geometry_msgs.msg import PoseStamped from image_caption_machine.utils import get_pose_stamped from image_caption_machine.world.place import Place from image_caption_machine.navigator.abstract import Abstract class Helper(Abstract): """Utility class to manage navigation with DFNav. """ def __init__(self): """Initialize the publishers and subscribers. """ self.tf_buffer = tf2_ros.Buffer() self.tf_listener = tf2_ros.TransformListener( self.tf_buffer) self.goal_publisher = rospy.Publisher( "/goal", PoseStamped, queue_size=2) self.goal_subscriber = rospy.Subscriber( "/goal", PoseStamped, self.handle_goal, queue_size=2) self.abort_publisher = rospy.Publisher( "/df/replan/abort", Bool, queue_size=1) self.abort_subscriber = rospy.Subscriber( "/df/replan/abort", Bool, self.handle_abort, queue_size=1) self.replan_time = None self.replan_sub = rospy.Subscriber( '/df/traj', TrajWithBackup, self.handle_replan, queue_size=10) self.is_finished = True self.on_complete = (lambda: None) def handle_goal(self, goal_pose): """Calculate if we are close enough to the goal. """ transform = self.tf_buffer.lookup_transform( "map", "body", rospy.Time(0)) goal_pose = tf2_geometry_msgs.do_transform_pose( goal_pose, transform) def update(): """Checks whether the navigation is finished. """ replan_expired = (self.replan_time is not None and ( rospy.Time.now() - self.replan_time).to_sec() > 4.0) curr_pose = get_pose_stamped(self.tf_buffer) near_goal = (curr_pose is not None and ( Place(pose_stamped=curr_pose).to(Place(pose_stamped=goal_pose)) < 0.1)) self.is_finished = (replan_expired or near_goal) r = rospy.Rate(10) self.is_finished = False while not rospy.is_shutdown() and not self.is_finished: update() r.sleep() self.replan_time = None self.on_complete() def handle_abort(self, abort): """Should the navigation be aborted. """ if abort.data: self.is_finished = True def handle_replan(self, plan): """Track the replan time of dfnav to determine completion. """ self.replan_time = rospy.Time.now() def go(self, goal_pose): """Start a navigation command """ if self.is_finished: transform = self.tf_buffer.lookup_transform( "body", "map", rospy.Time(0)) goal_pose = tf2_geometry_msgs.do_transform_pose( goal_pose, transform) self.goal_publisher.publish(goal_pose) def callback(self, fn): """Callback function runs after goal is reached or aborted. """ def _on_complete(): """Runs after navigation finishes. """ fn() self.on_complete = (lambda: None) self.is_finished = True self.on_complete = _on_complete def finished(self): """Check if the navigation is finished. """ return self.is_finished def abort(self): """Quickly halt the navigation process. """ self.abort_publisher.publish(Bool(True))
Kequc/adstack
lib/adstack/helper/network_setting.rb
<reponame>Kequc/adstack module Adstack class NetworkSetting < Helper ATTRIBUTES = [:google_search, :search_network, :content_network, :partner_search_network] attr_accessor *ATTRIBUTES def initialize(params={}) params.symbolize_all_keys! ATTRIBUTES.each do |symbol| params[symbol] = params.delete("target_#{symbol}".to_sym) if params[symbol].nil? # Store as boolean true by default params[symbol] = true if params[symbol].nil? params[symbol] = !!params[symbol] end super(ATTRIBUTES, params) end def writeable_attributes params = super result = {} ATTRIBUTES.each do |symbol| result["target_#{symbol}".to_sym] = params[symbol] end result end end end
jackleland/flopter
flopter/magnum/adcdata.py
<reponame>jackleland/flopter<gh_stars>1-10 import numpy as np import flopter.magnum.readfastadc as radc from flopter.core import constants as c class MagnumAdcConfig(object): def __init__(self, sample_rate, sample_time=None, num_samples=None, channels=None): self.sample_rate = sample_rate if sample_time: self.sample_time = sample_time self.num_samples = sample_rate * sample_time elif num_samples: self.num_samples = num_samples self.sample_time = num_samples / sample_rate else: raise ValueError('Initiation of MagnumAdcConfig requires one of sample_time or num_samples to not be None.') if not channels: raise ValueError('Channel list (with amplification and offset) required for schema definition.') else: assert isinstance(channels, dict) self.channels = channels @classmethod def parse_from_header(cls, header): # TODO: Implement this? May not be necessary as header container may suffice pass class MagnumAdcData(object): _DEFAULT_CHANNELS = { 0: [1.0, 0], 2: [1.0, 0], 5: [1.0, 0], 6: [1.0, 0], 7: [1.0, 0] } _DEFAULT_SCHEMA = MagnumAdcConfig(250000.0, 20.0, channels=_DEFAULT_CHANNELS) def __init__(self, full_path, file): self.full_path = full_path self.filename = file self.header, self.data = radc.process_adc_file(full_path, file) self.channels = list(self.data.keys()) # Create time array self.time = np.linspace(0, (self.header[c.MAGADC_NUM] / self.header[c.MAGADC_FREQ]), self.header[c.MAGADC_NUM])
Crypto-APIs/Crypto_APIs_2.0_SDK_Golang
api_unified_endpoints.go
/* CryptoAPIs Crypto APIs 2.0 is a complex and innovative infrastructure layer that radically simplifies the development of any Blockchain and Crypto related applications. Organized around REST, Crypto APIs 2.0 can assist both novice Bitcoin/Ethereum enthusiasts and crypto experts with the development of their blockchain applications. Crypto APIs 2.0 provides unified endpoints and data, raw data, automatic tokens and coins forwardings, callback functionalities, and much more. API version: 2.0.0 Contact: <EMAIL> */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. package cryptoapis import ( "bytes" _context "context" _ioutil "io/ioutil" _nethttp "net/http" _neturl "net/url" "strings" ) // Linger please var ( _ _context.Context ) // UnifiedEndpointsApiService UnifiedEndpointsApi service type UnifiedEndpointsApiService service type ApiGetAddressDetailsRequest struct { ctx _context.Context ApiService *UnifiedEndpointsApiService blockchain string network string address string context *string } // In batch situations the user can use the context to correlate responses with requests. This property is present regardless of whether the response was successful or returned as an error. &#x60;context&#x60; is specified by the user. func (r ApiGetAddressDetailsRequest) Context(context string) ApiGetAddressDetailsRequest { r.context = &context return r } func (r ApiGetAddressDetailsRequest) Execute() (GetAddressDetailsR, *_nethttp.Response, error) { return r.ApiService.GetAddressDetailsExecute(r) } /* GetAddressDetails Get Address Details Through this endpoint the customer can receive basic information about a given address based on confirmed/synced blocks only. In the case where there are any incoming or outgoing **unconfirmed** transactions for the specific address, they **will not** be counted or calculated here. Applies only for coins. @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). @param blockchain Represents the specific blockchain protocol name, e.g. Ethereum, Bitcoin, etc. @param network Represents the name of the blockchain network used; blockchain networks are usually identical as technology and software, but they differ in data, e.g. - \"mainnet\" is the live network with actual data while networks like \"testnet\", \"ropsten\" are test networks. @param address Represents the public address, which is a compressed and shortened form of a public key. @return ApiGetAddressDetailsRequest */ func (a *UnifiedEndpointsApiService) GetAddressDetails(ctx _context.Context, blockchain string, network string, address string) ApiGetAddressDetailsRequest { return ApiGetAddressDetailsRequest{ ApiService: a, ctx: ctx, blockchain: blockchain, network: network, address: address, } } // Execute executes the request // @return GetAddressDetailsR func (a *UnifiedEndpointsApiService) GetAddressDetailsExecute(r ApiGetAddressDetailsRequest) (GetAddressDetailsR, *_nethttp.Response, error) { var ( localVarHTTPMethod = _nethttp.MethodGet localVarPostBody interface{} formFiles []formFile localVarReturnValue GetAddressDetailsR ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "UnifiedEndpointsApiService.GetAddressDetails") if err != nil { return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/blockchain-data/{blockchain}/{network}/addresses/{address}" localVarPath = strings.Replace(localVarPath, "{"+"blockchain"+"}", _neturl.PathEscape(parameterToString(r.blockchain, "")), -1) localVarPath = strings.Replace(localVarPath, "{"+"network"+"}", _neturl.PathEscape(parameterToString(r.network, "")), -1) localVarPath = strings.Replace(localVarPath, "{"+"address"+"}", _neturl.PathEscape(parameterToString(r.address, "")), -1) localVarHeaderParams := make(map[string]string) localVarQueryParams := _neturl.Values{} localVarFormParams := _neturl.Values{} if r.context != nil { localVarQueryParams.Add("context", parameterToString(*r.context, "")) } // to determine the Content-Type header localVarHTTPContentTypes := []string{} // set Content-Type header localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) if localVarHTTPContentType != "" { localVarHeaderParams["Content-Type"] = localVarHTTPContentType } // to determine the Accept header localVarHTTPHeaderAccepts := []string{"application/json"} // set Accept header localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) if localVarHTTPHeaderAccept != "" { localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept } if r.ctx != nil { // API Key Authentication if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { if apiKey, ok := auth["ApiKey"]; ok { var key string if apiKey.Prefix != "" { key = apiKey.Prefix + " " + apiKey.Key } else { key = apiKey.Key } localVarHeaderParams["x-api-key"] = key } } } req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } localVarHTTPResponse, err := a.client.callAPI(req) if err != nil || localVarHTTPResponse == nil { return localVarReturnValue, localVarHTTPResponse, err } localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { newErr := GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } if localVarHTTPResponse.StatusCode == 400 { var v InlineResponse400 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 401 { var v InlineResponse401 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 402 { var v InlineResponse402 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 403 { var v InlineResponse403 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 409 { var v InlineResponse409 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 415 { var v InlineResponse415 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 422 { var v InlineResponse422 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 429 { var v InlineResponse429 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 500 { var v InlineResponse500 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v } return localVarReturnValue, localVarHTTPResponse, newErr } err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr := GenericOpenAPIError{ body: localVarBody, error: err.Error(), } return localVarReturnValue, localVarHTTPResponse, newErr } return localVarReturnValue, localVarHTTPResponse, nil } type ApiGetBlockDetailsByBlockHashRequest struct { ctx _context.Context ApiService *UnifiedEndpointsApiService blockchain string network string blockHash string context *string } // In batch situations the user can use the context to correlate responses with requests. This property is present regardless of whether the response was successful or returned as an error. &#x60;context&#x60; is specified by the user. func (r ApiGetBlockDetailsByBlockHashRequest) Context(context string) ApiGetBlockDetailsByBlockHashRequest { r.context = &context return r } func (r ApiGetBlockDetailsByBlockHashRequest) Execute() (GetBlockDetailsByBlockHashR, *_nethttp.Response, error) { return r.ApiService.GetBlockDetailsByBlockHashExecute(r) } /* GetBlockDetailsByBlockHash Get Block Details By Block Hash Through this endpoint customers can obtain basic information about a given mined block, specifically by using the `hash` parameter. These block details could include the hash of the specific, the previous and the next block, its transactions count, its height, etc. Blockchain specific data is information such as version, nonce, size, bits, merkleroot, etc. @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). @param blockchain Represents the specific blockchain protocol name, e.g. Ethereum, Bitcoin, etc. @param network Represents the name of the blockchain network used; blockchain networks are usually identical as technology and software, but they differ in data, e.g. - \"mainnet\" is the live network with actual data while networks like \"testnet\", \"ropsten\" are test networks. @param blockHash Represents the hash of the block, which is its unique identifier. It represents a cryptographic digital fingerprint made by hashing the block header twice through the SHA256 algorithm. @return ApiGetBlockDetailsByBlockHashRequest */ func (a *UnifiedEndpointsApiService) GetBlockDetailsByBlockHash(ctx _context.Context, blockchain string, network string, blockHash string) ApiGetBlockDetailsByBlockHashRequest { return ApiGetBlockDetailsByBlockHashRequest{ ApiService: a, ctx: ctx, blockchain: blockchain, network: network, blockHash: blockHash, } } // Execute executes the request // @return GetBlockDetailsByBlockHashR func (a *UnifiedEndpointsApiService) GetBlockDetailsByBlockHashExecute(r ApiGetBlockDetailsByBlockHashRequest) (GetBlockDetailsByBlockHashR, *_nethttp.Response, error) { var ( localVarHTTPMethod = _nethttp.MethodGet localVarPostBody interface{} formFiles []formFile localVarReturnValue GetBlockDetailsByBlockHashR ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "UnifiedEndpointsApiService.GetBlockDetailsByBlockHash") if err != nil { return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/blockchain-data/{blockchain}/{network}/blocks/hash/{blockHash}" localVarPath = strings.Replace(localVarPath, "{"+"blockchain"+"}", _neturl.PathEscape(parameterToString(r.blockchain, "")), -1) localVarPath = strings.Replace(localVarPath, "{"+"network"+"}", _neturl.PathEscape(parameterToString(r.network, "")), -1) localVarPath = strings.Replace(localVarPath, "{"+"blockHash"+"}", _neturl.PathEscape(parameterToString(r.blockHash, "")), -1) localVarHeaderParams := make(map[string]string) localVarQueryParams := _neturl.Values{} localVarFormParams := _neturl.Values{} if r.context != nil { localVarQueryParams.Add("context", parameterToString(*r.context, "")) } // to determine the Content-Type header localVarHTTPContentTypes := []string{} // set Content-Type header localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) if localVarHTTPContentType != "" { localVarHeaderParams["Content-Type"] = localVarHTTPContentType } // to determine the Accept header localVarHTTPHeaderAccepts := []string{"application/json"} // set Accept header localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) if localVarHTTPHeaderAccept != "" { localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept } if r.ctx != nil { // API Key Authentication if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { if apiKey, ok := auth["ApiKey"]; ok { var key string if apiKey.Prefix != "" { key = apiKey.Prefix + " " + apiKey.Key } else { key = apiKey.Key } localVarHeaderParams["x-api-key"] = key } } } req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } localVarHTTPResponse, err := a.client.callAPI(req) if err != nil || localVarHTTPResponse == nil { return localVarReturnValue, localVarHTTPResponse, err } localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { newErr := GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } if localVarHTTPResponse.StatusCode == 400 { var v InlineResponse40030 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 401 { var v InlineResponse40130 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 402 { var v InlineResponse402 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 403 { var v InlineResponse40330 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 404 { var v InlineResponse4042 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 409 { var v InlineResponse409 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 415 { var v InlineResponse415 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 422 { var v InlineResponse422 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 429 { var v InlineResponse429 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 500 { var v InlineResponse500 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v } return localVarReturnValue, localVarHTTPResponse, newErr } err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr := GenericOpenAPIError{ body: localVarBody, error: err.Error(), } return localVarReturnValue, localVarHTTPResponse, newErr } return localVarReturnValue, localVarHTTPResponse, nil } type ApiGetBlockDetailsByBlockHeightRequest struct { ctx _context.Context ApiService *UnifiedEndpointsApiService blockchain string network string height int32 context *string } // In batch situations the user can use the context to correlate responses with requests. This property is present regardless of whether the response was successful or returned as an error. &#x60;context&#x60; is specified by the user. func (r ApiGetBlockDetailsByBlockHeightRequest) Context(context string) ApiGetBlockDetailsByBlockHeightRequest { r.context = &context return r } func (r ApiGetBlockDetailsByBlockHeightRequest) Execute() (GetBlockDetailsByBlockHeightR, *_nethttp.Response, error) { return r.ApiService.GetBlockDetailsByBlockHeightExecute(r) } /* GetBlockDetailsByBlockHeight Get Block Details By Block Height Through this endpoint customers can obtain basic information about a given mined block, specifically by using the `height` parameter. These block details could include the hash of the specific, the previous and the next block, its transactions count, its height, etc. Blockchain specific data is information such as version, nonce, size, bits, merkleroot, etc. @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). @param blockchain Represents the specific blockchain protocol name, e.g. Ethereum, Bitcoin, etc. @param network Represents the name of the blockchain network used; blockchain networks are usually identical as technology and software, but they differ in data, e.g. - \"mainnet\" is the live network with actual data while networks like \"testnet\", \"ropsten\" are test networks. @param height Represents the number of blocks in the blockchain preceding this specific block. Block numbers have no gaps. A blockchain usually starts with block 0 called the \"Genesis block\". @return ApiGetBlockDetailsByBlockHeightRequest */ func (a *UnifiedEndpointsApiService) GetBlockDetailsByBlockHeight(ctx _context.Context, blockchain string, network string, height int32) ApiGetBlockDetailsByBlockHeightRequest { return ApiGetBlockDetailsByBlockHeightRequest{ ApiService: a, ctx: ctx, blockchain: blockchain, network: network, height: height, } } // Execute executes the request // @return GetBlockDetailsByBlockHeightR func (a *UnifiedEndpointsApiService) GetBlockDetailsByBlockHeightExecute(r ApiGetBlockDetailsByBlockHeightRequest) (GetBlockDetailsByBlockHeightR, *_nethttp.Response, error) { var ( localVarHTTPMethod = _nethttp.MethodGet localVarPostBody interface{} formFiles []formFile localVarReturnValue GetBlockDetailsByBlockHeightR ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "UnifiedEndpointsApiService.GetBlockDetailsByBlockHeight") if err != nil { return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/blockchain-data/{blockchain}/{network}/blocks/height/{height}" localVarPath = strings.Replace(localVarPath, "{"+"blockchain"+"}", _neturl.PathEscape(parameterToString(r.blockchain, "")), -1) localVarPath = strings.Replace(localVarPath, "{"+"network"+"}", _neturl.PathEscape(parameterToString(r.network, "")), -1) localVarPath = strings.Replace(localVarPath, "{"+"height"+"}", _neturl.PathEscape(parameterToString(r.height, "")), -1) localVarHeaderParams := make(map[string]string) localVarQueryParams := _neturl.Values{} localVarFormParams := _neturl.Values{} if r.context != nil { localVarQueryParams.Add("context", parameterToString(*r.context, "")) } // to determine the Content-Type header localVarHTTPContentTypes := []string{} // set Content-Type header localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) if localVarHTTPContentType != "" { localVarHeaderParams["Content-Type"] = localVarHTTPContentType } // to determine the Accept header localVarHTTPHeaderAccepts := []string{"application/json"} // set Accept header localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) if localVarHTTPHeaderAccept != "" { localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept } if r.ctx != nil { // API Key Authentication if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { if apiKey, ok := auth["ApiKey"]; ok { var key string if apiKey.Prefix != "" { key = apiKey.Prefix + " " + apiKey.Key } else { key = apiKey.Key } localVarHeaderParams["x-api-key"] = key } } } req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } localVarHTTPResponse, err := a.client.callAPI(req) if err != nil || localVarHTTPResponse == nil { return localVarReturnValue, localVarHTTPResponse, err } localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { newErr := GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } if localVarHTTPResponse.StatusCode == 400 { var v InlineResponse40026 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 401 { var v InlineResponse40126 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 402 { var v InlineResponse402 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 403 { var v InlineResponse40326 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 404 { var v InlineResponse4042 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 409 { var v InlineResponse409 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 415 { var v InlineResponse415 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 422 { var v InlineResponse422 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 429 { var v InlineResponse429 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 500 { var v InlineResponse500 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v } return localVarReturnValue, localVarHTTPResponse, newErr } err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr := GenericOpenAPIError{ body: localVarBody, error: err.Error(), } return localVarReturnValue, localVarHTTPResponse, newErr } return localVarReturnValue, localVarHTTPResponse, nil } type ApiGetFeeRecommendationsRequest struct { ctx _context.Context ApiService *UnifiedEndpointsApiService blockchain string network string context *string } // In batch situations the user can use the context to correlate responses with requests. This property is present regardless of whether the response was successful or returned as an error. &#x60;context&#x60; is specified by the user. func (r ApiGetFeeRecommendationsRequest) Context(context string) ApiGetFeeRecommendationsRequest { r.context = &context return r } func (r ApiGetFeeRecommendationsRequest) Execute() (GetFeeRecommendationsR, *_nethttp.Response, error) { return r.ApiService.GetFeeRecommendationsExecute(r) } /* GetFeeRecommendations Get Fee Recommendations Through this endpoint customers can obtain fee recommendations. Our fees recommendations are based on Mempool data which makes them much more accurate than fees based on already mined blocks. Calculations are done in real time live. Using this endpoint customers can get gas price for Ethereum, fee per byte for Bitcoin, etc. @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). @param blockchain Represents the specific blockchain protocol name, e.g. Ethereum, Bitcoin, etc. @param network Represents the name of the blockchain network used; blockchain networks are usually identical as technology and software, but they differ in data, e.g. - \"mainnet\" is the live network with actual data while networks like \"testnet\", \"ropsten\" are test networks. @return ApiGetFeeRecommendationsRequest */ func (a *UnifiedEndpointsApiService) GetFeeRecommendations(ctx _context.Context, blockchain string, network string) ApiGetFeeRecommendationsRequest { return ApiGetFeeRecommendationsRequest{ ApiService: a, ctx: ctx, blockchain: blockchain, network: network, } } // Execute executes the request // @return GetFeeRecommendationsR func (a *UnifiedEndpointsApiService) GetFeeRecommendationsExecute(r ApiGetFeeRecommendationsRequest) (GetFeeRecommendationsR, *_nethttp.Response, error) { var ( localVarHTTPMethod = _nethttp.MethodGet localVarPostBody interface{} formFiles []formFile localVarReturnValue GetFeeRecommendationsR ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "UnifiedEndpointsApiService.GetFeeRecommendations") if err != nil { return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/blockchain-data/{blockchain}/{network}/mempool/fees" localVarPath = strings.Replace(localVarPath, "{"+"blockchain"+"}", _neturl.PathEscape(parameterToString(r.blockchain, "")), -1) localVarPath = strings.Replace(localVarPath, "{"+"network"+"}", _neturl.PathEscape(parameterToString(r.network, "")), -1) localVarHeaderParams := make(map[string]string) localVarQueryParams := _neturl.Values{} localVarFormParams := _neturl.Values{} if r.context != nil { localVarQueryParams.Add("context", parameterToString(*r.context, "")) } // to determine the Content-Type header localVarHTTPContentTypes := []string{} // set Content-Type header localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) if localVarHTTPContentType != "" { localVarHeaderParams["Content-Type"] = localVarHTTPContentType } // to determine the Accept header localVarHTTPHeaderAccepts := []string{"application/json"} // set Accept header localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) if localVarHTTPHeaderAccept != "" { localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept } if r.ctx != nil { // API Key Authentication if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { if apiKey, ok := auth["ApiKey"]; ok { var key string if apiKey.Prefix != "" { key = apiKey.Prefix + " " + apiKey.Key } else { key = apiKey.Key } localVarHeaderParams["x-api-key"] = key } } } req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } localVarHTTPResponse, err := a.client.callAPI(req) if err != nil || localVarHTTPResponse == nil { return localVarReturnValue, localVarHTTPResponse, err } localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { newErr := GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } if localVarHTTPResponse.StatusCode == 400 { var v InlineResponse40053 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 401 { var v InlineResponse40153 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 402 { var v InlineResponse402 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 403 { var v InlineResponse40353 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 404 { var v InlineResponse4041 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 409 { var v InlineResponse409 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 415 { var v InlineResponse415 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 422 { var v InlineResponse422 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 429 { var v InlineResponse429 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 500 { var v InlineResponse500 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v } return localVarReturnValue, localVarHTTPResponse, newErr } err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr := GenericOpenAPIError{ body: localVarBody, error: err.Error(), } return localVarReturnValue, localVarHTTPResponse, newErr } return localVarReturnValue, localVarHTTPResponse, nil } type ApiGetLastMinedBlockRequest struct { ctx _context.Context ApiService *UnifiedEndpointsApiService blockchain string network string context *string } // In batch situations the user can use the context to correlate responses with requests. This property is present regardless of whether the response was successful or returned as an error. &#x60;context&#x60; is specified by the user. func (r ApiGetLastMinedBlockRequest) Context(context string) ApiGetLastMinedBlockRequest { r.context = &context return r } func (r ApiGetLastMinedBlockRequest) Execute() (GetLastMinedBlockR, *_nethttp.Response, error) { return r.ApiService.GetLastMinedBlockExecute(r) } /* GetLastMinedBlock Get Last Mined Block Through this endpoint customers can fetch the last mined block in a specific blockchain network, along with its details. These could include the hash of the specific, the previous and the next block, its transactions count, its height, etc. Blockchain specific data is information such as version, nonce, size, bits, merkleroot, etc. @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). @param blockchain Represents the specific blockchain protocol name, e.g. Ethereum, Bitcoin, etc. @param network Represents the name of the blockchain network used; blockchain networks are usually identical as technology and software, but they differ in data, e.g. - \"mainnet\" is the live network with actual data while networks like \"testnet\", \"ropsten\" are test networks. @return ApiGetLastMinedBlockRequest */ func (a *UnifiedEndpointsApiService) GetLastMinedBlock(ctx _context.Context, blockchain string, network string) ApiGetLastMinedBlockRequest { return ApiGetLastMinedBlockRequest{ ApiService: a, ctx: ctx, blockchain: blockchain, network: network, } } // Execute executes the request // @return GetLastMinedBlockR func (a *UnifiedEndpointsApiService) GetLastMinedBlockExecute(r ApiGetLastMinedBlockRequest) (GetLastMinedBlockR, *_nethttp.Response, error) { var ( localVarHTTPMethod = _nethttp.MethodGet localVarPostBody interface{} formFiles []formFile localVarReturnValue GetLastMinedBlockR ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "UnifiedEndpointsApiService.GetLastMinedBlock") if err != nil { return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/blockchain-data/{blockchain}/{network}/blocks/last" localVarPath = strings.Replace(localVarPath, "{"+"blockchain"+"}", _neturl.PathEscape(parameterToString(r.blockchain, "")), -1) localVarPath = strings.Replace(localVarPath, "{"+"network"+"}", _neturl.PathEscape(parameterToString(r.network, "")), -1) localVarHeaderParams := make(map[string]string) localVarQueryParams := _neturl.Values{} localVarFormParams := _neturl.Values{} if r.context != nil { localVarQueryParams.Add("context", parameterToString(*r.context, "")) } // to determine the Content-Type header localVarHTTPContentTypes := []string{} // set Content-Type header localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) if localVarHTTPContentType != "" { localVarHeaderParams["Content-Type"] = localVarHTTPContentType } // to determine the Accept header localVarHTTPHeaderAccepts := []string{"application/json"} // set Accept header localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) if localVarHTTPHeaderAccept != "" { localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept } if r.ctx != nil { // API Key Authentication if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { if apiKey, ok := auth["ApiKey"]; ok { var key string if apiKey.Prefix != "" { key = apiKey.Prefix + " " + apiKey.Key } else { key = apiKey.Key } localVarHeaderParams["x-api-key"] = key } } } req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } localVarHTTPResponse, err := a.client.callAPI(req) if err != nil || localVarHTTPResponse == nil { return localVarReturnValue, localVarHTTPResponse, err } localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { newErr := GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } if localVarHTTPResponse.StatusCode == 400 { var v InlineResponse40037 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 401 { var v InlineResponse40137 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 402 { var v InlineResponse402 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 403 { var v InlineResponse40337 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 404 { var v InlineResponse4042 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 409 { var v InlineResponse409 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 415 { var v InlineResponse415 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 422 { var v InlineResponse422 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 429 { var v InlineResponse429 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 500 { var v InlineResponse500 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v } return localVarReturnValue, localVarHTTPResponse, newErr } err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr := GenericOpenAPIError{ body: localVarBody, error: err.Error(), } return localVarReturnValue, localVarHTTPResponse, newErr } return localVarReturnValue, localVarHTTPResponse, nil } type ApiGetTransactionDetailsByTransactionIDRequest struct { ctx _context.Context ApiService *UnifiedEndpointsApiService blockchain string network string transactionId string context *string } // In batch situations the user can use the context to correlate responses with requests. This property is present regardless of whether the response was successful or returned as an error. &#x60;context&#x60; is specified by the user. func (r ApiGetTransactionDetailsByTransactionIDRequest) Context(context string) ApiGetTransactionDetailsByTransactionIDRequest { r.context = &context return r } func (r ApiGetTransactionDetailsByTransactionIDRequest) Execute() (GetTransactionDetailsByTransactionIDR, *_nethttp.Response, error) { return r.ApiService.GetTransactionDetailsByTransactionIDExecute(r) } /* GetTransactionDetailsByTransactionID Get Transaction Details By Transaction ID Through this endpoint customers can obtain details about a transaction by the transaction's unique identifier. In UTXO-based protocols like BTC there are attributes such as `transactionId` and transaction `hash`. They still could be different. In protocols like Ethereum there is only one unique value and it's `hash`. @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). @param blockchain Represents the specific blockchain protocol name, e.g. Ethereum, Bitcoin, etc. @param network Represents the name of the blockchain network used; blockchain networks are usually identical as technology and software, but they differ in data, e.g. - \"mainnet\" is the live network with actual data while networks like \"testnet\", \"ropsten\" are test networks. @param transactionId Represents the unique identifier of a transaction, i.e. it could be `transactionId` in UTXO-based protocols like Bitcoin, and transaction `hash` in Ethereum blockchain. @return ApiGetTransactionDetailsByTransactionIDRequest */ func (a *UnifiedEndpointsApiService) GetTransactionDetailsByTransactionID(ctx _context.Context, blockchain string, network string, transactionId string) ApiGetTransactionDetailsByTransactionIDRequest { return ApiGetTransactionDetailsByTransactionIDRequest{ ApiService: a, ctx: ctx, blockchain: blockchain, network: network, transactionId: transactionId, } } // Execute executes the request // @return GetTransactionDetailsByTransactionIDR func (a *UnifiedEndpointsApiService) GetTransactionDetailsByTransactionIDExecute(r ApiGetTransactionDetailsByTransactionIDRequest) (GetTransactionDetailsByTransactionIDR, *_nethttp.Response, error) { var ( localVarHTTPMethod = _nethttp.MethodGet localVarPostBody interface{} formFiles []formFile localVarReturnValue GetTransactionDetailsByTransactionIDR ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "UnifiedEndpointsApiService.GetTransactionDetailsByTransactionID") if err != nil { return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/blockchain-data/{blockchain}/{network}/transactions/{transactionId}" localVarPath = strings.Replace(localVarPath, "{"+"blockchain"+"}", _neturl.PathEscape(parameterToString(r.blockchain, "")), -1) localVarPath = strings.Replace(localVarPath, "{"+"network"+"}", _neturl.PathEscape(parameterToString(r.network, "")), -1) localVarPath = strings.Replace(localVarPath, "{"+"transactionId"+"}", _neturl.PathEscape(parameterToString(r.transactionId, "")), -1) localVarHeaderParams := make(map[string]string) localVarQueryParams := _neturl.Values{} localVarFormParams := _neturl.Values{} if r.context != nil { localVarQueryParams.Add("context", parameterToString(*r.context, "")) } // to determine the Content-Type header localVarHTTPContentTypes := []string{} // set Content-Type header localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) if localVarHTTPContentType != "" { localVarHeaderParams["Content-Type"] = localVarHTTPContentType } // to determine the Accept header localVarHTTPHeaderAccepts := []string{"application/json"} // set Accept header localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) if localVarHTTPHeaderAccept != "" { localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept } if r.ctx != nil { // API Key Authentication if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { if apiKey, ok := auth["ApiKey"]; ok { var key string if apiKey.Prefix != "" { key = apiKey.Prefix + " " + apiKey.Key } else { key = apiKey.Key } localVarHeaderParams["x-api-key"] = key } } } req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } localVarHTTPResponse, err := a.client.callAPI(req) if err != nil || localVarHTTPResponse == nil { return localVarReturnValue, localVarHTTPResponse, err } localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { newErr := GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } if localVarHTTPResponse.StatusCode == 400 { var v InlineResponse4004 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 401 { var v InlineResponse4014 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 402 { var v InlineResponse402 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 403 { var v InlineResponse4034 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 404 { var v InlineResponse404 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 409 { var v InlineResponse409 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 415 { var v InlineResponse415 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 422 { var v InlineResponse422 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 429 { var v InlineResponse429 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 500 { var v InlineResponse500 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v } return localVarReturnValue, localVarHTTPResponse, newErr } err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr := GenericOpenAPIError{ body: localVarBody, error: err.Error(), } return localVarReturnValue, localVarHTTPResponse, newErr } return localVarReturnValue, localVarHTTPResponse, nil } type ApiListAllUnconfirmedTransactionsRequest struct { ctx _context.Context ApiService *UnifiedEndpointsApiService blockchain string network string context *string limit *int32 offset *int32 } // In batch situations the user can use the context to correlate responses with requests. This property is present regardless of whether the response was successful or returned as an error. &#x60;context&#x60; is specified by the user. func (r ApiListAllUnconfirmedTransactionsRequest) Context(context string) ApiListAllUnconfirmedTransactionsRequest { r.context = &context return r } // Defines how many items should be returned in the response per page basis. func (r ApiListAllUnconfirmedTransactionsRequest) Limit(limit int32) ApiListAllUnconfirmedTransactionsRequest { r.limit = &limit return r } // The starting index of the response items, i.e. where the response should start listing the returned items. func (r ApiListAllUnconfirmedTransactionsRequest) Offset(offset int32) ApiListAllUnconfirmedTransactionsRequest { r.offset = &offset return r } func (r ApiListAllUnconfirmedTransactionsRequest) Execute() (ListAllUnconfirmedTransactionsR, *_nethttp.Response, error) { return r.ApiService.ListAllUnconfirmedTransactionsExecute(r) } /* ListAllUnconfirmedTransactions List All Unconfirmed Transactions Through this endpoint customers can list all **unconfirmed** transactions for a specified blockchain and network. @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). @param blockchain Represents the specific blockchain protocol name, e.g. Ethereum, Bitcoin, etc. @param network Represents the name of the blockchain network used; blockchain networks are usually identical as technology and software, but they differ in data, e.g. - \"mainnet\" is the live network with actual data while networks like \"testnet\", \"ropsten\" are test networks. @return ApiListAllUnconfirmedTransactionsRequest */ func (a *UnifiedEndpointsApiService) ListAllUnconfirmedTransactions(ctx _context.Context, blockchain string, network string) ApiListAllUnconfirmedTransactionsRequest { return ApiListAllUnconfirmedTransactionsRequest{ ApiService: a, ctx: ctx, blockchain: blockchain, network: network, } } // Execute executes the request // @return ListAllUnconfirmedTransactionsR func (a *UnifiedEndpointsApiService) ListAllUnconfirmedTransactionsExecute(r ApiListAllUnconfirmedTransactionsRequest) (ListAllUnconfirmedTransactionsR, *_nethttp.Response, error) { var ( localVarHTTPMethod = _nethttp.MethodGet localVarPostBody interface{} formFiles []formFile localVarReturnValue ListAllUnconfirmedTransactionsR ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "UnifiedEndpointsApiService.ListAllUnconfirmedTransactions") if err != nil { return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/blockchain-data/{blockchain}/{network}/address-transactions-unconfirmed" localVarPath = strings.Replace(localVarPath, "{"+"blockchain"+"}", _neturl.PathEscape(parameterToString(r.blockchain, "")), -1) localVarPath = strings.Replace(localVarPath, "{"+"network"+"}", _neturl.PathEscape(parameterToString(r.network, "")), -1) localVarHeaderParams := make(map[string]string) localVarQueryParams := _neturl.Values{} localVarFormParams := _neturl.Values{} if r.context != nil { localVarQueryParams.Add("context", parameterToString(*r.context, "")) } if r.limit != nil { localVarQueryParams.Add("limit", parameterToString(*r.limit, "")) } if r.offset != nil { localVarQueryParams.Add("offset", parameterToString(*r.offset, "")) } // to determine the Content-Type header localVarHTTPContentTypes := []string{} // set Content-Type header localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) if localVarHTTPContentType != "" { localVarHeaderParams["Content-Type"] = localVarHTTPContentType } // to determine the Accept header localVarHTTPHeaderAccepts := []string{"application/json"} // set Accept header localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) if localVarHTTPHeaderAccept != "" { localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept } if r.ctx != nil { // API Key Authentication if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { if apiKey, ok := auth["ApiKey"]; ok { var key string if apiKey.Prefix != "" { key = apiKey.Prefix + " " + apiKey.Key } else { key = apiKey.Key } localVarHeaderParams["x-api-key"] = key } } } req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } localVarHTTPResponse, err := a.client.callAPI(req) if err != nil || localVarHTTPResponse == nil { return localVarReturnValue, localVarHTTPResponse, err } localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { newErr := GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } if localVarHTTPResponse.StatusCode == 400 { var v InlineResponse40016 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 401 { var v InlineResponse40116 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 402 { var v InlineResponse402 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 403 { var v InlineResponse40316 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 409 { var v InlineResponse409 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 415 { var v InlineResponse415 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 422 { var v InlineResponse422 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 429 { var v InlineResponse429 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 500 { var v InlineResponse500 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v } return localVarReturnValue, localVarHTTPResponse, newErr } err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr := GenericOpenAPIError{ body: localVarBody, error: err.Error(), } return localVarReturnValue, localVarHTTPResponse, newErr } return localVarReturnValue, localVarHTTPResponse, nil } type ApiListConfirmedTransactionsByAddressRequest struct { ctx _context.Context ApiService *UnifiedEndpointsApiService blockchain string network string address string context *string limit *int32 offset *int32 } // In batch situations the user can use the context to correlate responses with requests. This property is present regardless of whether the response was successful or returned as an error. &#x60;context&#x60; is specified by the user. func (r ApiListConfirmedTransactionsByAddressRequest) Context(context string) ApiListConfirmedTransactionsByAddressRequest { r.context = &context return r } // Defines how many items should be returned in the response per page basis. func (r ApiListConfirmedTransactionsByAddressRequest) Limit(limit int32) ApiListConfirmedTransactionsByAddressRequest { r.limit = &limit return r } // The starting index of the response items, i.e. where the response should start listing the returned items. func (r ApiListConfirmedTransactionsByAddressRequest) Offset(offset int32) ApiListConfirmedTransactionsByAddressRequest { r.offset = &offset return r } func (r ApiListConfirmedTransactionsByAddressRequest) Execute() (ListConfirmedTransactionsByAddressR, *_nethttp.Response, error) { return r.ApiService.ListConfirmedTransactionsByAddressExecute(r) } /* ListConfirmedTransactionsByAddress List Confirmed Transactions By Address This endpoint will list transactions by an attribute `address`. The transactions listed will detail additional information such as hash, height, time of creation in Unix timestamp, etc. @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). @param blockchain Represents the specific blockchain protocol name, e.g. Ethereum, Bitcoin, etc. @param network Represents the name of the blockchain network used; blockchain networks are usually identical as technology and software, but they differ in data, e.g. - \"mainnet\" is the live network with actual data while networks like \"testnet\", \"ropsten\" are test networks. @param address Represents the public address, which is a compressed and shortened form of a public key. @return ApiListConfirmedTransactionsByAddressRequest */ func (a *UnifiedEndpointsApiService) ListConfirmedTransactionsByAddress(ctx _context.Context, blockchain string, network string, address string) ApiListConfirmedTransactionsByAddressRequest { return ApiListConfirmedTransactionsByAddressRequest{ ApiService: a, ctx: ctx, blockchain: blockchain, network: network, address: address, } } // Execute executes the request // @return ListConfirmedTransactionsByAddressR func (a *UnifiedEndpointsApiService) ListConfirmedTransactionsByAddressExecute(r ApiListConfirmedTransactionsByAddressRequest) (ListConfirmedTransactionsByAddressR, *_nethttp.Response, error) { var ( localVarHTTPMethod = _nethttp.MethodGet localVarPostBody interface{} formFiles []formFile localVarReturnValue ListConfirmedTransactionsByAddressR ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "UnifiedEndpointsApiService.ListConfirmedTransactionsByAddress") if err != nil { return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/blockchain-data/{blockchain}/{network}/addresses/{address}/transactions" localVarPath = strings.Replace(localVarPath, "{"+"blockchain"+"}", _neturl.PathEscape(parameterToString(r.blockchain, "")), -1) localVarPath = strings.Replace(localVarPath, "{"+"network"+"}", _neturl.PathEscape(parameterToString(r.network, "")), -1) localVarPath = strings.Replace(localVarPath, "{"+"address"+"}", _neturl.PathEscape(parameterToString(r.address, "")), -1) localVarHeaderParams := make(map[string]string) localVarQueryParams := _neturl.Values{} localVarFormParams := _neturl.Values{} if r.context != nil { localVarQueryParams.Add("context", parameterToString(*r.context, "")) } if r.limit != nil { localVarQueryParams.Add("limit", parameterToString(*r.limit, "")) } if r.offset != nil { localVarQueryParams.Add("offset", parameterToString(*r.offset, "")) } // to determine the Content-Type header localVarHTTPContentTypes := []string{} // set Content-Type header localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) if localVarHTTPContentType != "" { localVarHeaderParams["Content-Type"] = localVarHTTPContentType } // to determine the Accept header localVarHTTPHeaderAccepts := []string{"application/json"} // set Accept header localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) if localVarHTTPHeaderAccept != "" { localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept } if r.ctx != nil { // API Key Authentication if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { if apiKey, ok := auth["ApiKey"]; ok { var key string if apiKey.Prefix != "" { key = apiKey.Prefix + " " + apiKey.Key } else { key = apiKey.Key } localVarHeaderParams["x-api-key"] = key } } } req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } localVarHTTPResponse, err := a.client.callAPI(req) if err != nil || localVarHTTPResponse == nil { return localVarReturnValue, localVarHTTPResponse, err } localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { newErr := GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } if localVarHTTPResponse.StatusCode == 400 { var v InlineResponse40010 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 401 { var v InlineResponse40110 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 402 { var v InlineResponse402 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 403 { var v InlineResponse40310 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 409 { var v InlineResponse409 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 415 { var v InlineResponse415 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 422 { var v InlineResponse422 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 429 { var v InlineResponse429 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 500 { var v InlineResponse500 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v } return localVarReturnValue, localVarHTTPResponse, newErr } err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr := GenericOpenAPIError{ body: localVarBody, error: err.Error(), } return localVarReturnValue, localVarHTTPResponse, newErr } return localVarReturnValue, localVarHTTPResponse, nil } type ApiListLatestMinedBlocksRequest struct { ctx _context.Context ApiService *UnifiedEndpointsApiService network string blockchain string count int32 context *string } // In batch situations the user can use the context to correlate responses with requests. This property is present regardless of whether the response was successful or returned as an error. &#x60;context&#x60; is specified by the user. func (r ApiListLatestMinedBlocksRequest) Context(context string) ApiListLatestMinedBlocksRequest { r.context = &context return r } func (r ApiListLatestMinedBlocksRequest) Execute() (ListLatestMinedBlocksR, *_nethttp.Response, error) { return r.ApiService.ListLatestMinedBlocksExecute(r) } /* ListLatestMinedBlocks List Latest Mined Blocks Through this endpoint customers can list **up to 50** from the latest blocks that were mined. @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). @param network Represents the name of the blockchain network used; blockchain networks are usually identical as technology and software, but they differ in data, e.g. - \"mainnet\" is the live network with actual data while networks like \"testnet\", \"ropsten\" are test networks @param blockchain Represents the specific blockchain protocol name, e.g. Ethereum, Bitcoin, etc. @param count Specifies how many records were requested. @return ApiListLatestMinedBlocksRequest */ func (a *UnifiedEndpointsApiService) ListLatestMinedBlocks(ctx _context.Context, network string, blockchain string, count int32) ApiListLatestMinedBlocksRequest { return ApiListLatestMinedBlocksRequest{ ApiService: a, ctx: ctx, network: network, blockchain: blockchain, count: count, } } // Execute executes the request // @return ListLatestMinedBlocksR func (a *UnifiedEndpointsApiService) ListLatestMinedBlocksExecute(r ApiListLatestMinedBlocksRequest) (ListLatestMinedBlocksR, *_nethttp.Response, error) { var ( localVarHTTPMethod = _nethttp.MethodGet localVarPostBody interface{} formFiles []formFile localVarReturnValue ListLatestMinedBlocksR ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "UnifiedEndpointsApiService.ListLatestMinedBlocks") if err != nil { return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/blockchain-data/{blockchain}/{network}/blocks/last/{count}" localVarPath = strings.Replace(localVarPath, "{"+"network"+"}", _neturl.PathEscape(parameterToString(r.network, "")), -1) localVarPath = strings.Replace(localVarPath, "{"+"blockchain"+"}", _neturl.PathEscape(parameterToString(r.blockchain, "")), -1) localVarPath = strings.Replace(localVarPath, "{"+"count"+"}", _neturl.PathEscape(parameterToString(r.count, "")), -1) localVarHeaderParams := make(map[string]string) localVarQueryParams := _neturl.Values{} localVarFormParams := _neturl.Values{} if r.context != nil { localVarQueryParams.Add("context", parameterToString(*r.context, "")) } // to determine the Content-Type header localVarHTTPContentTypes := []string{} // set Content-Type header localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) if localVarHTTPContentType != "" { localVarHeaderParams["Content-Type"] = localVarHTTPContentType } // to determine the Accept header localVarHTTPHeaderAccepts := []string{"application/json"} // set Accept header localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) if localVarHTTPHeaderAccept != "" { localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept } if r.ctx != nil { // API Key Authentication if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { if apiKey, ok := auth["ApiKey"]; ok { var key string if apiKey.Prefix != "" { key = apiKey.Prefix + " " + apiKey.Key } else { key = apiKey.Key } localVarHeaderParams["x-api-key"] = key } } } req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } localVarHTTPResponse, err := a.client.callAPI(req) if err != nil || localVarHTTPResponse == nil { return localVarReturnValue, localVarHTTPResponse, err } localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { newErr := GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } if localVarHTTPResponse.StatusCode == 400 { var v InlineResponse40042 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 401 { var v InlineResponse40142 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 402 { var v InlineResponse402 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 403 { var v InlineResponse40342 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 404 { var v InlineResponse4041 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 409 { var v InlineResponse409 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 415 { var v InlineResponse415 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 422 { var v InlineResponse422 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 429 { var v InlineResponse429 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 500 { var v InlineResponse500 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v } return localVarReturnValue, localVarHTTPResponse, newErr } err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr := GenericOpenAPIError{ body: localVarBody, error: err.Error(), } return localVarReturnValue, localVarHTTPResponse, newErr } return localVarReturnValue, localVarHTTPResponse, nil } type ApiListTransactionsByBlockHashRequest struct { ctx _context.Context ApiService *UnifiedEndpointsApiService blockchain string network string blockHash string context *string limit *int32 offset *int32 } // In batch situations the user can use the context to correlate responses with requests. This property is present regardless of whether the response was successful or returned as an error. &#x60;context&#x60; is specified by the user. func (r ApiListTransactionsByBlockHashRequest) Context(context string) ApiListTransactionsByBlockHashRequest { r.context = &context return r } // Defines how many items should be returned in the response per page basis. func (r ApiListTransactionsByBlockHashRequest) Limit(limit int32) ApiListTransactionsByBlockHashRequest { r.limit = &limit return r } // The starting index of the response items, i.e. where the response should start listing the returned items. func (r ApiListTransactionsByBlockHashRequest) Offset(offset int32) ApiListTransactionsByBlockHashRequest { r.offset = &offset return r } func (r ApiListTransactionsByBlockHashRequest) Execute() (ListTransactionsByBlockHashR, *_nethttp.Response, error) { return r.ApiService.ListTransactionsByBlockHashExecute(r) } /* ListTransactionsByBlockHash List Transactions by Block Hash This endpoint will list transactions by an attribute `transactionHash`. The transactions listed will detail additional information such as addresses, height, time of creation in Unix timestamp, etc. @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). @param blockchain Represents the specific blockchain protocol name, e.g. Ethereum, Bitcoin, etc. @param network Represents the name of the blockchain network used; blockchain networks are usually identical as technology and software, but they differ in data, e.g. - \"mainnet\" is the live network with actual data while networks like \"testnet\", \"ropsten\" are test networks. @param blockHash Represents the hash of the block, which is its unique identifier. It represents a cryptographic digital fingerprint made by hashing the block header twice through the SHA256 algorithm. @return ApiListTransactionsByBlockHashRequest */ func (a *UnifiedEndpointsApiService) ListTransactionsByBlockHash(ctx _context.Context, blockchain string, network string, blockHash string) ApiListTransactionsByBlockHashRequest { return ApiListTransactionsByBlockHashRequest{ ApiService: a, ctx: ctx, blockchain: blockchain, network: network, blockHash: blockHash, } } // Execute executes the request // @return ListTransactionsByBlockHashR func (a *UnifiedEndpointsApiService) ListTransactionsByBlockHashExecute(r ApiListTransactionsByBlockHashRequest) (ListTransactionsByBlockHashR, *_nethttp.Response, error) { var ( localVarHTTPMethod = _nethttp.MethodGet localVarPostBody interface{} formFiles []formFile localVarReturnValue ListTransactionsByBlockHashR ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "UnifiedEndpointsApiService.ListTransactionsByBlockHash") if err != nil { return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/blockchain-data/{blockchain}/{network}/blocks/hash/{blockHash}/transactions" localVarPath = strings.Replace(localVarPath, "{"+"blockchain"+"}", _neturl.PathEscape(parameterToString(r.blockchain, "")), -1) localVarPath = strings.Replace(localVarPath, "{"+"network"+"}", _neturl.PathEscape(parameterToString(r.network, "")), -1) localVarPath = strings.Replace(localVarPath, "{"+"blockHash"+"}", _neturl.PathEscape(parameterToString(r.blockHash, "")), -1) localVarHeaderParams := make(map[string]string) localVarQueryParams := _neturl.Values{} localVarFormParams := _neturl.Values{} if r.context != nil { localVarQueryParams.Add("context", parameterToString(*r.context, "")) } if r.limit != nil { localVarQueryParams.Add("limit", parameterToString(*r.limit, "")) } if r.offset != nil { localVarQueryParams.Add("offset", parameterToString(*r.offset, "")) } // to determine the Content-Type header localVarHTTPContentTypes := []string{} // set Content-Type header localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) if localVarHTTPContentType != "" { localVarHeaderParams["Content-Type"] = localVarHTTPContentType } // to determine the Accept header localVarHTTPHeaderAccepts := []string{"application/json"} // set Accept header localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) if localVarHTTPHeaderAccept != "" { localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept } if r.ctx != nil { // API Key Authentication if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { if apiKey, ok := auth["ApiKey"]; ok { var key string if apiKey.Prefix != "" { key = apiKey.Prefix + " " + apiKey.Key } else { key = apiKey.Key } localVarHeaderParams["x-api-key"] = key } } } req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } localVarHTTPResponse, err := a.client.callAPI(req) if err != nil || localVarHTTPResponse == nil { return localVarReturnValue, localVarHTTPResponse, err } localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { newErr := GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } if localVarHTTPResponse.StatusCode == 400 { var v InlineResponse40017 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 401 { var v InlineResponse40117 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 402 { var v InlineResponse402 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 403 { var v InlineResponse40317 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 409 { var v InlineResponse409 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 415 { var v InlineResponse415 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 422 { var v InlineResponse422 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 429 { var v InlineResponse429 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 500 { var v InlineResponse500 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v } return localVarReturnValue, localVarHTTPResponse, newErr } err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr := GenericOpenAPIError{ body: localVarBody, error: err.Error(), } return localVarReturnValue, localVarHTTPResponse, newErr } return localVarReturnValue, localVarHTTPResponse, nil } type ApiListTransactionsByBlockHeightRequest struct { ctx _context.Context ApiService *UnifiedEndpointsApiService blockchain string network string height int32 context *string limit *int32 offset *int32 } // In batch situations the user can use the context to correlate responses with requests. This property is present regardless of whether the response was successful or returned as an error. &#x60;context&#x60; is specified by the user. func (r ApiListTransactionsByBlockHeightRequest) Context(context string) ApiListTransactionsByBlockHeightRequest { r.context = &context return r } // Defines how many items should be returned in the response per page basis. func (r ApiListTransactionsByBlockHeightRequest) Limit(limit int32) ApiListTransactionsByBlockHeightRequest { r.limit = &limit return r } // The starting index of the response items, i.e. where the response should start listing the returned items. func (r ApiListTransactionsByBlockHeightRequest) Offset(offset int32) ApiListTransactionsByBlockHeightRequest { r.offset = &offset return r } func (r ApiListTransactionsByBlockHeightRequest) Execute() (ListTransactionsByBlockHeightR, *_nethttp.Response, error) { return r.ApiService.ListTransactionsByBlockHeightExecute(r) } /* ListTransactionsByBlockHeight List Transactions by Block Height This endpoint will list transactions by an attribute `blockHeight`. The transactions listed will detail additional information such as hash, addresses, time of creation in Unix timestamp, etc. @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). @param blockchain Represents the specific blockchain protocol name, e.g. Ethereum, Bitcoin, etc. @param network Represents the name of the blockchain network used; blockchain networks are usually identical as technology and software, but they differ in data, e.g. - \"mainnet\" is the live network with actual data while networks like \"testnet\", \"ropsten\" are test networks. @param height Represents the number of blocks in the blockchain preceding this specific block. Block numbers have no gaps. A blockchain usually starts with block 0 called the \"Genesis block\". @return ApiListTransactionsByBlockHeightRequest */ func (a *UnifiedEndpointsApiService) ListTransactionsByBlockHeight(ctx _context.Context, blockchain string, network string, height int32) ApiListTransactionsByBlockHeightRequest { return ApiListTransactionsByBlockHeightRequest{ ApiService: a, ctx: ctx, blockchain: blockchain, network: network, height: height, } } // Execute executes the request // @return ListTransactionsByBlockHeightR func (a *UnifiedEndpointsApiService) ListTransactionsByBlockHeightExecute(r ApiListTransactionsByBlockHeightRequest) (ListTransactionsByBlockHeightR, *_nethttp.Response, error) { var ( localVarHTTPMethod = _nethttp.MethodGet localVarPostBody interface{} formFiles []formFile localVarReturnValue ListTransactionsByBlockHeightR ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "UnifiedEndpointsApiService.ListTransactionsByBlockHeight") if err != nil { return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/blockchain-data/{blockchain}/{network}/blocks/height/{height}/transactions" localVarPath = strings.Replace(localVarPath, "{"+"blockchain"+"}", _neturl.PathEscape(parameterToString(r.blockchain, "")), -1) localVarPath = strings.Replace(localVarPath, "{"+"network"+"}", _neturl.PathEscape(parameterToString(r.network, "")), -1) localVarPath = strings.Replace(localVarPath, "{"+"height"+"}", _neturl.PathEscape(parameterToString(r.height, "")), -1) localVarHeaderParams := make(map[string]string) localVarQueryParams := _neturl.Values{} localVarFormParams := _neturl.Values{} if r.context != nil { localVarQueryParams.Add("context", parameterToString(*r.context, "")) } if r.limit != nil { localVarQueryParams.Add("limit", parameterToString(*r.limit, "")) } if r.offset != nil { localVarQueryParams.Add("offset", parameterToString(*r.offset, "")) } // to determine the Content-Type header localVarHTTPContentTypes := []string{} // set Content-Type header localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) if localVarHTTPContentType != "" { localVarHeaderParams["Content-Type"] = localVarHTTPContentType } // to determine the Accept header localVarHTTPHeaderAccepts := []string{"application/json"} // set Accept header localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) if localVarHTTPHeaderAccept != "" { localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept } if r.ctx != nil { // API Key Authentication if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { if apiKey, ok := auth["ApiKey"]; ok { var key string if apiKey.Prefix != "" { key = apiKey.Prefix + " " + apiKey.Key } else { key = apiKey.Key } localVarHeaderParams["x-api-key"] = key } } } req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } localVarHTTPResponse, err := a.client.callAPI(req) if err != nil || localVarHTTPResponse == nil { return localVarReturnValue, localVarHTTPResponse, err } localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { newErr := GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } if localVarHTTPResponse.StatusCode == 400 { var v InlineResponse40024 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 401 { var v InlineResponse40124 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 402 { var v InlineResponse402 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 403 { var v InlineResponse40324 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 404 { var v InlineResponse4042 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 409 { var v InlineResponse409 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 415 { var v InlineResponse415 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 422 { var v InlineResponse422 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 429 { var v InlineResponse429 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 500 { var v InlineResponse500 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v } return localVarReturnValue, localVarHTTPResponse, newErr } err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr := GenericOpenAPIError{ body: localVarBody, error: err.Error(), } return localVarReturnValue, localVarHTTPResponse, newErr } return localVarReturnValue, localVarHTTPResponse, nil } type ApiListUnconfirmedTransactionsByAddressRequest struct { ctx _context.Context ApiService *UnifiedEndpointsApiService blockchain string network string address string context *string limit *int32 offset *int32 } // In batch situations the user can use the context to correlate responses with requests. This property is present regardless of whether the response was successful or returned as an error. &#x60;context&#x60; is specified by the user. func (r ApiListUnconfirmedTransactionsByAddressRequest) Context(context string) ApiListUnconfirmedTransactionsByAddressRequest { r.context = &context return r } // Defines how many items should be returned in the response per page basis. func (r ApiListUnconfirmedTransactionsByAddressRequest) Limit(limit int32) ApiListUnconfirmedTransactionsByAddressRequest { r.limit = &limit return r } // The starting index of the response items, i.e. where the response should start listing the returned items. func (r ApiListUnconfirmedTransactionsByAddressRequest) Offset(offset int32) ApiListUnconfirmedTransactionsByAddressRequest { r.offset = &offset return r } func (r ApiListUnconfirmedTransactionsByAddressRequest) Execute() (ListUnconfirmedTransactionsByAddressR, *_nethttp.Response, error) { return r.ApiService.ListUnconfirmedTransactionsByAddressExecute(r) } /* ListUnconfirmedTransactionsByAddress List Unconfirmed Transactions by Address Through this endpoint customers can list transactions by `address` that are **unconfirmed**. @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). @param blockchain Represents the specific blockchain protocol name, e.g. Ethereum, Bitcoin, etc. @param network Represents the name of the blockchain network used; blockchain networks are usually identical as technology and software, but they differ in data, e.g. - \"mainnet\" is the live network with actual data while networks like \"testnet\", \"ropsten\" are test networks. @param address Represents the public address, which is a compressed and shortened form of a public key. @return ApiListUnconfirmedTransactionsByAddressRequest */ func (a *UnifiedEndpointsApiService) ListUnconfirmedTransactionsByAddress(ctx _context.Context, blockchain string, network string, address string) ApiListUnconfirmedTransactionsByAddressRequest { return ApiListUnconfirmedTransactionsByAddressRequest{ ApiService: a, ctx: ctx, blockchain: blockchain, network: network, address: address, } } // Execute executes the request // @return ListUnconfirmedTransactionsByAddressR func (a *UnifiedEndpointsApiService) ListUnconfirmedTransactionsByAddressExecute(r ApiListUnconfirmedTransactionsByAddressRequest) (ListUnconfirmedTransactionsByAddressR, *_nethttp.Response, error) { var ( localVarHTTPMethod = _nethttp.MethodGet localVarPostBody interface{} formFiles []formFile localVarReturnValue ListUnconfirmedTransactionsByAddressR ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "UnifiedEndpointsApiService.ListUnconfirmedTransactionsByAddress") if err != nil { return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/blockchain-data/{blockchain}/{network}/address-transactions-unconfirmed/{address}" localVarPath = strings.Replace(localVarPath, "{"+"blockchain"+"}", _neturl.PathEscape(parameterToString(r.blockchain, "")), -1) localVarPath = strings.Replace(localVarPath, "{"+"network"+"}", _neturl.PathEscape(parameterToString(r.network, "")), -1) localVarPath = strings.Replace(localVarPath, "{"+"address"+"}", _neturl.PathEscape(parameterToString(r.address, "")), -1) localVarHeaderParams := make(map[string]string) localVarQueryParams := _neturl.Values{} localVarFormParams := _neturl.Values{} if r.context != nil { localVarQueryParams.Add("context", parameterToString(*r.context, "")) } if r.limit != nil { localVarQueryParams.Add("limit", parameterToString(*r.limit, "")) } if r.offset != nil { localVarQueryParams.Add("offset", parameterToString(*r.offset, "")) } // to determine the Content-Type header localVarHTTPContentTypes := []string{} // set Content-Type header localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) if localVarHTTPContentType != "" { localVarHeaderParams["Content-Type"] = localVarHTTPContentType } // to determine the Accept header localVarHTTPHeaderAccepts := []string{"application/json"} // set Accept header localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) if localVarHTTPHeaderAccept != "" { localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept } if r.ctx != nil { // API Key Authentication if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { if apiKey, ok := auth["ApiKey"]; ok { var key string if apiKey.Prefix != "" { key = apiKey.Prefix + " " + apiKey.Key } else { key = apiKey.Key } localVarHeaderParams["x-api-key"] = key } } } req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } localVarHTTPResponse, err := a.client.callAPI(req) if err != nil || localVarHTTPResponse == nil { return localVarReturnValue, localVarHTTPResponse, err } localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { newErr := GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } if localVarHTTPResponse.StatusCode == 400 { var v InlineResponse40015 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 401 { var v InlineResponse40115 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 402 { var v InlineResponse402 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 403 { var v InlineResponse40315 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 409 { var v InlineResponse409 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 415 { var v InlineResponse415 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 422 { var v InlineResponse422 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 429 { var v InlineResponse429 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v return localVarReturnValue, localVarHTTPResponse, newErr } if localVarHTTPResponse.StatusCode == 500 { var v InlineResponse500 err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() return localVarReturnValue, localVarHTTPResponse, newErr } newErr.model = v } return localVarReturnValue, localVarHTTPResponse, newErr } err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { newErr := GenericOpenAPIError{ body: localVarBody, error: err.Error(), } return localVarReturnValue, localVarHTTPResponse, newErr } return localVarReturnValue, localVarHTTPResponse, nil }
cpplibv/libv
src/libv/utility/intrusive_ref.hpp
<reponame>cpplibv/libv<filename>src/libv/utility/intrusive_ref.hpp // Project: libv.utility, File: src/libv/utility/intrusive_ref.hpp, Author: <NAME> [Vader] #pragma once // pro #include <libv/utility/intrusive_ptr.hpp> namespace libv { // ------------------------------------------------------------------------------------------------- template <typename T> using intrusive_ref = intrusive_ptr<T>; template <typename T, typename... Args> intrusive_ref<T> make_intrusive_ref(Args&&... args) { return intrusive_ref<T>(new T(std::forward<Args>(args)...)); } // ------------------------------------------------------------------------------------------------- } // namespace std
reiform/celix
examples/celix-examples/services_example_c/src/simple_consumer_example.c
<filename>examples/celix-examples/services_example_c/src/simple_consumer_example.c /* * Licensed to the Apache Software Foundation (ASF) under one * or more contributor license agreements. See the NOTICE file * distributed with this work for additional information * regarding copyright ownership. The ASF licenses this file * to you under the Apache License, Version 2.0 (the * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY * KIND, either express or implied. See the License for the * specific language governing permissions and limitations * under the License. */ #include <unistd.h> #include <stdio.h> #include <stdlib.h> #include <string.h> #include <celix_api.h> #include "example_calc.h" typedef struct activator_data { celix_bundle_context_t *ctx; long trkId; } activator_data_t; static void addSvc(activator_data_t *data __attribute__((unused)), example_calc_t *calc) { int result = calc->calc(calc->handle, 2); printf("Added calc service, result is %i\n", result); } static void removeSvc(activator_data_t *data __attribute__((unused)), example_calc_t *calc) { int result = calc->calc(calc->handle, 3); printf("Removing calc service, result is %i\n", result); } static void useCalc(activator_data_t *data __attribute__((unused)), example_calc_t *calc) { int result = calc->calc(calc->handle, 2); printf("Called highest ranking service. Result is %i\n", result); } static celix_status_t activator_start(activator_data_t *data, celix_bundle_context_t *ctx) { data->ctx = ctx; data->trkId = -1L; printf("Starting service tracker\n"); data->trkId = celix_bundleContext_trackServices(data->ctx, EXAMPLE_CALC_NAME, data, (void*)addSvc, (void*)removeSvc); printf("Trying to use calc service\n"); celix_bundleContext_useService(data->ctx, EXAMPLE_CALC_NAME, data, (void*)useCalc); return CELIX_SUCCESS; } static celix_status_t activator_stop(activator_data_t *data, celix_bundle_context_t *ctx) { celix_bundleContext_stopTracker(data->ctx, data->trkId); return CELIX_SUCCESS; } CELIX_GEN_BUNDLE_ACTIVATOR(activator_data_t, activator_start, activator_stop)
bygui86/spring-validation
src/test/java/com/rabbit/validationsamples/integrations/ProfileWrapperDtoValidationIntegrationTest.java
package com.rabbit.validationsamples.integrations; import com.rabbit.validationsamples.dtos.ProfileDto; import com.rabbit.validationsamples.dtos.ProfileWrapperDto; import org.junit.Assert; import org.junit.BeforeClass; import org.junit.Test; import javax.validation.ConstraintViolation; import javax.validation.Validation; import javax.validation.Validator; import javax.validation.ValidatorFactory; import java.util.Set; public class ProfileWrapperDtoValidationIntegrationTest { private static Validator validator; @BeforeClass public static void setup() { final ValidatorFactory factory = Validation.buildDefaultValidatorFactory(); validator = factory.getValidator(); } @Test public void validateProfileWrapper_ok() { final Set<ConstraintViolation<ProfileWrapperDto>> violations = validator.validate( ProfileWrapperDto.builder() .profile( ProfileDto.builder() .companyName("MB SOLID consulting") .build() ) .build() ); Assert.assertTrue(violations.isEmpty()); } @Test public void validateProfileWrapper_error() { final Set<ConstraintViolation<ProfileWrapperDto>> violations = validator.validate( ProfileWrapperDto.builder() .profile( ProfileDto.builder() .companyName("") .build() ) .build() ); Assert.assertFalse(violations.isEmpty()); Assert.assertEquals(1, violations.size()); } }
oweson/ruoyi
ruoyi-system/src/main/java/com/ruoyi/system/domain/BasWord.java
package com.ruoyi.system.domain; import org.apache.commons.lang3.builder.ToStringBuilder; import org.apache.commons.lang3.builder.ToStringStyle; import com.ruoyi.common.annotation.Excel; import com.ruoyi.common.core.domain.BaseEntity; /** * word对象 bas_word * * @author ruoyi * @date 2020-08-06 */ public class BasWord extends BaseEntity { private static final long serialVersionUID = 1L; /** null */ private Long id; /** null */ @Excel(name = "null") private String word; /** 繁体字 */ @Excel(name = "繁体字") private String oldword; /** null */ @Excel(name = "null") private String pinyin; /** 偏旁 */ @Excel(name = "偏旁") private String radicals; /** 笔画 */ @Excel(name = "笔画") private Long strokes; /** 解释 */ @Excel(name = "解释") private String explanation; /** 更多 */ @Excel(name = "更多") private String more; /** null */ @Excel(name = "null") private Long addUserId; public void setId(Long id) { this.id = id; } public Long getId() { return id; } public void setWord(String word) { this.word = word; } public String getWord() { return word; } public void setOldword(String oldword) { this.oldword = oldword; } public String getOldword() { return oldword; } public void setPinyin(String pinyin) { this.pinyin = pinyin; } public String getPinyin() { return pinyin; } public void setRadicals(String radicals) { this.radicals = radicals; } public String getRadicals() { return radicals; } public void setStrokes(Long strokes) { this.strokes = strokes; } public Long getStrokes() { return strokes; } public void setExplanation(String explanation) { this.explanation = explanation; } public String getExplanation() { return explanation; } public void setMore(String more) { this.more = more; } public String getMore() { return more; } public void setAddUserId(Long addUserId) { this.addUserId = addUserId; } public Long getAddUserId() { return addUserId; } @Override public String toString() { return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE) .append("id", getId()) .append("word", getWord()) .append("oldword", getOldword()) .append("pinyin", getPinyin()) .append("radicals", getRadicals()) .append("strokes", getStrokes()) .append("explanation", getExplanation()) .append("more", getMore()) .append("addUserId", getAddUserId()) .toString(); } }
impredator/dharma2018
src/main/java/com/dharma/patterns/gof/behavioral/visitor/DemoVisitor.java
<reponame>impredator/dharma2018 package com.dharma.patterns.gof.behavioral.visitor; interface Element { void accept(Visitor v); } class FOO implements Element { public void accept(Visitor v) { v.visit(this); } public String getFOO() { return "FOO"; } } class BAR implements Element { public void accept( Visitor v ) { v.visit( this ); } public String getBAR() { return "BAR"; } } class BAZ implements Element { public void accept(Visitor v) { v.visit(this); } public String getBAZ() { return "BAZ"; } } interface Visitor { void visit(FOO foo); void visit(BAR bar); void visit(BAZ baz); } class UpVisitor implements Visitor { public void visit(FOO foo) { System.out.println("do Up on " + foo.getFOO()); } public void visit(BAR bar) { System.out.println("do Up on " + bar.getBAR()); } public void visit(BAZ baz) { System.out.println( "do Up on " + baz.getBAZ() ); } } class DownVisitor implements Visitor { public void visit(FOO foo) { System.out.println("do Down on " + foo.getFOO()); } public void visit(BAR bar) { System.out.println("do Down on " + bar.getBAR()); } public void visit(BAZ baz ) { System.out.println("do Down on " + baz.getBAZ()); } } public class DemoVisitor { public static void main( String[] args ) { Element[] list = {new FOO(), new BAR(), new BAZ()}; UpVisitor up = new UpVisitor(); DownVisitor down = new DownVisitor(); for (Element element : list) { element.accept(up); } for (Element element : list) { element.accept(down); } } }
MateuszMazurkiewiczWaw/IntelligentTraderReactFlask
react_frontend/node_modules/mdi-react/QuestionNetworkIcon.js
'use strict'; function _interopDefault (ex) { return (ex && (typeof ex === 'object') && 'default' in ex) ? ex['default'] : ex; } var React = _interopDefault(require('react')); var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; var objectWithoutProperties = function (obj, keys) { var target = {}; for (var i in obj) { if (keys.indexOf(i) >= 0) continue; if (!Object.prototype.hasOwnProperty.call(obj, i)) continue; target[i] = obj[i]; } return target; }; var QuestionNetworkIcon = function QuestionNetworkIcon(_ref) { var _ref$color = _ref.color, color = _ref$color === undefined ? 'currentColor' : _ref$color, _ref$size = _ref.size, size = _ref$size === undefined ? 24 : _ref$size, children = _ref.children, props = objectWithoutProperties(_ref, ['color', 'size', 'children']); var className = 'mdi-icon ' + (props.className || ''); return React.createElement( 'svg', _extends({}, props, { className: className, width: size, height: size, fill: color, viewBox: '0 0 24 24' }), React.createElement('path', { d: 'M17,3A2,2 0 0,1 19,5V15A2,2 0 0,1 17,17H13V19H14A1,1 0 0,1 15,20H22V22H15A1,1 0 0,1 14,23H10A1,1 0 0,1 9,22H2V20H9A1,1 0 0,1 10,19H11V17H7C5.89,17 5,16.1 5,15V5A2,2 0 0,1 7,3H17M12.19,5C11.32,5 10.62,5.2 10.08,5.59C9.56,6 9.3,6.57 9.31,7.36L9.32,7.39H11.25C11.26,7.09 11.35,6.86 11.53,6.7C11.71,6.55 11.93,6.47 12.19,6.47C12.5,6.47 12.76,6.57 12.94,6.75C13.12,6.94 13.2,7.2 13.2,7.5C13.2,7.82 13.13,8.09 12.97,8.32C12.83,8.55 12.62,8.75 12.36,8.91C11.85,9.25 11.5,9.55 11.31,9.82C11.11,10.08 11,10.5 11,11H13C13,10.69 13.04,10.44 13.13,10.26C13.22,10.07 13.39,9.9 13.64,9.74C14.09,9.5 14.46,9.21 14.75,8.81C15.04,8.41 15.19,8 15.19,7.5C15.19,6.74 14.92,6.13 14.38,5.68C13.85,5.23 13.12,5 12.19,5M11,12V14H13V12H11Z' }) ); }; var QuestionNetworkIcon$1 = React.memo ? React.memo(QuestionNetworkIcon) : QuestionNetworkIcon; module.exports = QuestionNetworkIcon$1;
onmyway133/Runtime-Headers
macOS/10.13/AppKit.framework/NSRegularLegacyScrollerImp.h
/* Generated by RuntimeBrowser Image: /System/Library/Frameworks/AppKit.framework/Versions/C/AppKit */ @interface NSRegularLegacyScrollerImp : NSLegacyScrollerImp + (double)scrollerWidth; - (unsigned long long)controlSize; - (double)knobMinLength; - (void)loadImages; - (double)trackWidth; @end
avereon/cart2
source/main/java/com/avereon/cartesia/CartesiaDesignCodec.java
package com.avereon.cartesia; import com.avereon.cartesia.data.*; import com.avereon.cartesia.math.CadGeometry; import com.avereon.data.IdNode; import com.avereon.data.Node; import com.avereon.log.LazyEval; import com.avereon.product.Product; import com.avereon.util.TextUtil; import com.avereon.xenon.asset.Asset; import com.avereon.xenon.asset.Codec; import com.fasterxml.jackson.core.JsonGenerator; import com.fasterxml.jackson.core.type.TypeReference; import com.fasterxml.jackson.databind.JsonNode; import com.fasterxml.jackson.databind.JsonSerializer; import com.fasterxml.jackson.databind.ObjectMapper; import com.fasterxml.jackson.databind.SerializerProvider; import com.fasterxml.jackson.databind.module.SimpleModule; import javafx.geometry.Point2D; import javafx.geometry.Point3D; import javafx.scene.paint.Color; import lombok.CustomLog; import java.io.ByteArrayOutputStream; import java.io.IOException; import java.io.InputStream; import java.io.OutputStream; import java.util.*; import java.util.function.Function; import java.util.stream.Collectors; @CustomLog public abstract class CartesiaDesignCodec extends Codec { static final ObjectMapper JSON_MAPPER; static final String CODEC_VERSION_KEY = "codec-version"; static final String CODEC_VERSION = "1"; private static final String POINT = "point"; private static final String RADIUS = "radius"; private static final Map<String, String> savePaintMapping; private static final Map<String, String> loadPaintMapping; private static final Map<String, String> saveLayerToNullMapping; private static final Map<String, String> loadNullToLayerMapping; private final Product product; private final Map<Class<? extends DesignShape>, Function<DesignShape, Map<String, Object>>> geometryMappers; static { JSON_MAPPER = new ObjectMapper(); JSON_MAPPER.registerModule( new SimpleModule().addSerializer( Point2D.class, new Point2DSerializer() ) ); JSON_MAPPER.registerModule( new SimpleModule().addSerializer( Point3D.class, new Point3DSerializer() ) ); JSON_MAPPER.registerModule( new SimpleModule().addSerializer( Color.class, new ColorSerializer() ) ); savePaintMapping = Map.of( DesignDrawable.MODE_LAYER, "null", "null", "none" ); loadPaintMapping = Map.of( "none", "null", "null", DesignDrawable.MODE_LAYER ); saveLayerToNullMapping = Map.of( DesignDrawable.MODE_LAYER, "null", "null", "none" ); loadNullToLayerMapping = Map.of( "none", "null", "null", DesignDrawable.MODE_LAYER ); } public CartesiaDesignCodec( Product product ) { this.product = product; geometryMappers = new HashMap<>(); geometryMappers.put( DesignMarker.class, m -> mapMarker( (DesignMarker)m ) ); geometryMappers.put( DesignLine.class, m -> mapLine( (DesignLine)m ) ); geometryMappers.put( DesignEllipse.class, m -> mapEllipse( (DesignEllipse)m ) ); geometryMappers.put( DesignArc.class, m -> mapArc( (DesignArc)m ) ); geometryMappers.put( DesignCurve.class, m -> mapCurve( (DesignCurve)m ) ); } protected Product getProduct() { return product; } @Override public boolean canLoad() { return true; } @Override public boolean canSave() { return true; } @Override @SuppressWarnings( "unchecked" ) public void load( Asset asset, InputStream input ) throws IOException { Design2D design = asset.setModel( new Design2D() ); Map<String, Object> map = JSON_MAPPER.readValue( input, new TypeReference<>() {} ); design.updateFrom( map ); log.atFine().log( "Design codec version: %s", LazyEval.of( () -> map.get( CODEC_VERSION_KEY ) ) ); Map<String, Map<String, Object>> layers = (Map<String, Map<String, Object>>)map.getOrDefault( DesignLayer.LAYERS, Map.of() ); Map<String, Map<String, Object>> views = (Map<String, Map<String, Object>>)map.getOrDefault( Design.VIEWS, Map.of() ); // Load layers layers.values().forEach( l -> loadLayer( design.getLayers(), l ) ); // Load views views.values().forEach( v -> loadView( design, v ) ); asset.getUndoManager().forgetHistory(); } @Override public void save( Asset asset, OutputStream output ) throws IOException { Map<String, Object> map = mapDesign( asset.getModel() ); map.put( CODEC_VERSION_KEY, CODEC_VERSION ); JSON_MAPPER.writerWithDefaultPrettyPrinter().writeValue( output, map ); //System.err.println( JSON_MAPPER.writerWithDefaultPrettyPrinter().writeValueAsString( map ) ); } @SuppressWarnings( "unchecked" ) private void loadLayer( DesignLayer parent, Map<String, Object> map ) { DesignLayer layer = new DesignLayer().updateFrom( map ); parent.addLayer( layer ); // Add the shapes found in the layer Map<String, Map<String, Object>> geometry = (Map<String, Map<String, Object>>)map.getOrDefault( DesignLayer.SHAPES, Map.of() ); geometry.values().forEach( g -> { // Old keys moveKey( g, "draw-color", DesignDrawable.DRAW_PAINT ); moveKey( g, "fill-color", DesignDrawable.FILL_PAINT ); // Value mapping remapValue( g, DesignDrawable.DRAW_PAINT, loadPaintMapping ); remapValue( g, DesignDrawable.DRAW_WIDTH, loadNullToLayerMapping ); remapValue( g, DesignDrawable.DRAW_CAP, loadNullToLayerMapping ); remapValue( g, DesignDrawable.DRAW_PATTERN, loadNullToLayerMapping ); remapValue( g, DesignDrawable.FILL_PAINT, loadPaintMapping ); String type = String.valueOf( g.get( DesignShape.SHAPE ) ); DesignShape shape = switch( type ) { case DesignMarker.MARKER, POINT -> loadDesignMarker( g ); case DesignLine.LINE -> loadDesignLine( g ); case DesignEllipse.CIRCLE, DesignEllipse.ELLIPSE -> loadDesignEllipse( g ); case DesignArc.ARC -> loadDesignArc( g ); case DesignCurve.CURVE -> loadDesignCurve( g ); default -> null; }; layer.addShape( shape ); } ); Map<String, Map<String, Object>> layers = (Map<String, Map<String, Object>>)map.getOrDefault( DesignLayer.LAYERS, Map.of() ); layers.values().forEach( l -> loadLayer( layer, l ) ); } private void loadDesignNode( Map<String, Object> map, DesignNode node ) { if( map.containsKey( DesignNode.ID ) ) node.setId( (String)map.get( DesignNode.ID ) ); } @SuppressWarnings( "unchecked" ) private void loadView( Design design, Map<String, Object> map ) { DesignView view = new DesignView(); loadDesignNode( map, view ); if( map.containsKey( DesignView.NAME ) ) view.setName( (String)map.get( DesignView.NAME ) ); if( map.containsKey( DesignView.ORDER ) ) view.setOrder( Integer.parseInt( (String)map.get( DesignView.ORDER ) ) ); if( map.containsKey( DesignView.ORIGIN ) ) view.setOrigin( ParseUtil.parsePoint3D( (String)map.get( DesignView.ORIGIN ) ) ); if( map.containsKey( DesignView.ROTATE ) ) view.setRotate( ((Number)map.get( DesignView.ROTATE )).doubleValue() ); if( map.containsKey( DesignView.ZOOM ) ) view.setZoom( ((Number)map.get( DesignView.ZOOM )).doubleValue() ); List<String> layers = (List<String>)map.getOrDefault( DesignView.LAYERS, Set.of() ); view.setLayers( layers.stream().map( design::findLayerById ).filter( Objects::nonNull ).collect( Collectors.toSet() ) ); design.addView( view ); } private void loadDesignDrawable( Map<String, Object> map, DesignDrawable drawable ) { loadDesignNode( map, drawable ); // Fix bad data String drawPattern = (String)map.get( DesignDrawable.DRAW_PATTERN ); if( "0".equals( drawPattern ) ) drawPattern = null; if( "".equals( drawPattern ) ) drawPattern = null; if( map.containsKey( DesignDrawable.ORDER ) ) drawable.setOrder( (Integer)map.get( DesignDrawable.ORDER ) ); drawable.setDrawPaint( map.containsKey( DesignDrawable.DRAW_PAINT ) ? (String)map.get( DesignDrawable.DRAW_PAINT ) : null ); if( map.containsKey( DesignDrawable.DRAW_WIDTH ) ) drawable.setDrawWidth( (String)map.get( DesignDrawable.DRAW_WIDTH ) ); if( map.containsKey( DesignDrawable.DRAW_CAP ) ) drawable.setDrawCap( (String)map.get( DesignDrawable.DRAW_CAP ) ); if( map.containsKey( DesignDrawable.DRAW_PATTERN ) ) drawable.setDrawPattern( drawPattern ); drawable.setFillPaint( map.containsKey( DesignDrawable.FILL_PAINT ) ? (String)map.get( DesignDrawable.FILL_PAINT ) : null ); } private <T extends DesignShape> T loadDesignShape( Map<String, Object> map, T shape ) { loadDesignDrawable( map, shape ); if( map.containsKey( DesignShape.ORIGIN ) ) shape.setOrigin( ParseUtil.parsePoint3D( (String)map.get( DesignShape.ORIGIN ) ) ); return shape; } private DesignMarker loadDesignMarker( Map<String, Object> map ) { DesignMarker marker = loadDesignShape( map, new DesignMarker() ); marker.setSize( (String)map.get( DesignMarker.SIZE ) ); marker.setType( (String)map.get( DesignMarker.TYPE ) ); return marker; } private DesignLine loadDesignLine( Map<String, Object> map ) { DesignLine line = loadDesignShape( map, new DesignLine() ); line.setPoint( ParseUtil.parsePoint3D( (String)map.get( DesignLine.POINT ) ) ); return line; } private <T extends DesignEllipse> T loadDesignEllipse( Map<String, Object> map, T ellipse ) { if( map.containsKey( RADIUS ) ) ellipse.setXRadius( ((Number)map.get( RADIUS )).doubleValue() ); if( map.containsKey( RADIUS ) ) ellipse.setYRadius( ((Number)map.get( RADIUS )).doubleValue() ); if( map.containsKey( DesignEllipse.X_RADIUS ) ) ellipse.setXRadius( ((Number)map.get( DesignEllipse.X_RADIUS )).doubleValue() ); if( map.containsKey( DesignEllipse.Y_RADIUS ) ) ellipse.setYRadius( ((Number)map.get( DesignEllipse.Y_RADIUS )).doubleValue() ); if( map.containsKey( DesignEllipse.ROTATE ) ) ellipse.setRotate( ((Number)map.get( DesignEllipse.ROTATE )).doubleValue() ); return ellipse; } private DesignEllipse loadDesignEllipse( Map<String, Object> map ) { return loadDesignEllipse( map, loadDesignShape( map, new DesignEllipse() ) ); } private DesignArc loadDesignArc( Map<String, Object> map ) { DesignArc arc = loadDesignEllipse( map, loadDesignShape( map, new DesignArc() ) ); if( map.containsKey( DesignArc.START ) ) arc.setStart( ((Number)map.get( DesignArc.START )).doubleValue() ); if( map.containsKey( DesignArc.EXTENT ) ) arc.setExtent( ((Number)map.get( DesignArc.EXTENT )).doubleValue() ); if( map.containsKey( DesignArc.TYPE ) ) arc.setType( DesignArc.Type.valueOf( ((String)map.get( DesignArc.TYPE )).toUpperCase() ) ); return arc; } private DesignCurve loadDesignCurve( Map<String, Object> map ) { DesignCurve curve = loadDesignShape( map, new DesignCurve() ); curve.setOriginControl( ParseUtil.parsePoint3D( (String)map.get( DesignCurve.ORIGIN_CONTROL ) ) ); curve.setPointControl( ParseUtil.parsePoint3D( (String)map.get( DesignCurve.POINT_CONTROL ) ) ); curve.setPoint( ParseUtil.parsePoint3D( (String)map.get( DesignCurve.POINT ) ) ); return curve; } private void moveKey( Map<String, Object> map, String oldKey, String newKey ) { if( !map.containsKey( oldKey ) ) return; map.put( newKey, map.get( oldKey ) ); map.remove( oldKey ); } private Map<String, Object> mapDesign( Design design ) { Map<String, Object> map = new HashMap<>( asMap( design, Design.ID, Design.NAME, Design.AUTHOR, Design.DESCRIPTION, Design.UNIT ) ); map.put( Design.LAYERS, design.getLayers().getLayers().stream().collect( Collectors.toMap( IdNode::getId, this::mapLayer ) ) ); if( design.getViews().size() > 0 ) map.put( Design.VIEWS, design.getViews().stream().collect( Collectors.toMap( IdNode::getId, this::mapView ) ) ); return map; } private Map<String, Object> mapLayer( DesignLayer layer ) { Map<String, Object> map = new HashMap<>( asMap( layer, mapDrawable( layer ), Design.NAME ) ); map.put( DesignLayer.LAYERS, layer.getLayers().stream().collect( Collectors.toMap( IdNode::getId, this::mapLayer ) ) ); map.put( DesignLayer.SHAPES, layer.getShapes().stream().filter( s -> !s.isReference() ).collect( Collectors.toMap( IdNode::getId, this::mapGeometry ) ) ); return map; } private Map<String, Object> mapDesignNode( DesignNode node ) { return asMap( node, DesignNode.ID ); } private Map<String, Object> mapView( DesignView view ) { Map<String, Object> map = new HashMap<>( asMap( view, mapDesignNode( view ), DesignView.ORDER, DesignView.NAME, DesignView.ORIGIN, DesignView.ROTATE, DesignView.ZOOM ) ); map.put( DesignView.LAYERS, view.getLayers().stream().map( IdNode::getId ).collect( Collectors.toSet() ) ); return map; } private Map<String, Object> mapDrawable( DesignDrawable drawable ) { return asMap( drawable, mapDesignNode( drawable ), DesignDrawable.ORDER, DesignDrawable.DRAW_PAINT, DesignDrawable.DRAW_WIDTH, DesignDrawable.DRAW_PATTERN, DesignDrawable.DRAW_CAP, DesignDrawable.FILL_PAINT ); } private Map<String, Object> mapGeometry( DesignShape shape ) { return geometryMappers.get( shape.getClass() ).apply( shape ); } private Map<String, Object> mapShape( DesignShape shape, String type ) { Map<String, Object> map = asMap( shape, mapDrawable( shape ), DesignShape.ORIGIN ); map.put( DesignShape.SHAPE, type ); // Value mapping remapValue( map, DesignDrawable.DRAW_PAINT, savePaintMapping ); remapValue( map, DesignDrawable.DRAW_WIDTH, saveLayerToNullMapping ); remapValue( map, DesignDrawable.DRAW_CAP, saveLayerToNullMapping ); remapValue( map, DesignDrawable.DRAW_PATTERN, saveLayerToNullMapping ); remapValue( map, DesignDrawable.FILL_PAINT, savePaintMapping ); return map; } private Map<String, Object> mapMarker( DesignMarker marker ) { return asMap( marker, mapShape( marker, DesignMarker.MARKER ), DesignMarker.SIZE, DesignMarker.TYPE ); } private Map<String, Object> mapLine( DesignLine line ) { return asMap( line, mapShape( line, DesignLine.LINE ), DesignLine.POINT ); } private Map<String, Object> mapRadius( DesignEllipse ellipse ) { Map<String, Object> map = new HashMap<>(); if( CadGeometry.areSameSize( ellipse.getXRadius(), ellipse.getYRadius() ) ) { map.put( RADIUS, ellipse.getValue( DesignEllipse.X_RADIUS ) ); } else { map.putAll( asMap( ellipse, DesignEllipse.X_RADIUS, DesignEllipse.Y_RADIUS ) ); } return map; } private Map<String, Object> mapEllipse( DesignEllipse ellipse ) { String shape = Objects.equals( ellipse.getXRadius(), ellipse.getYRadius() ) ? DesignEllipse.CIRCLE : DesignEllipse.ELLIPSE; Map<String, Object> map = asMap( ellipse, mapShape( ellipse, shape ), DesignEllipse.ROTATE ); map.putAll( mapRadius( ellipse ) ); return map; } private Map<String, Object> mapArc( DesignArc arc ) { Map<String, Object> map = asMap( arc, mapShape( arc, DesignArc.ARC ), DesignArc.ROTATE, DesignArc.START, DesignArc.EXTENT, DesignArc.TYPE ); map.putAll( mapRadius( arc ) ); return map; } private Map<String, Object> mapCurve( DesignCurve curve ) { return asMap( curve, mapShape( curve, DesignCurve.CURVE ), DesignCurve.ORIGIN_CONTROL, DesignCurve.POINT_CONTROL, DesignCurve.POINT ); } private void remapValue( Map<String, Object> map, String key, Map<?, ?> values ) { Object currentValue = map.get( key ); if( currentValue == null ) currentValue = "null"; Object newValue = values.get( currentValue ); if( newValue == null ) return; if( "null".equals( newValue ) ) { map.remove( key ); } else { map.put( key, newValue ); } } private static Map<String, Object> asMap( Node node, String... keys ) { return asMap( node, Map.of(), keys ); } private static Map<String, Object> asMap( Node node, Map<String, Object> map, String... keys ) { Map<String, Object> result = new HashMap<>( map ); result.putAll( Arrays.stream( keys ).filter( k -> node.getValue( k ) != null ).collect( Collectors.toMap( k -> k, node::getValue ) ) ); return result; } @SuppressWarnings( "unused" ) String prettyPrint( byte[] buffer ) throws Exception { JsonNode node = JSON_MAPPER.readValue( buffer, JsonNode.class ); ByteArrayOutputStream output = new ByteArrayOutputStream(); JSON_MAPPER.writerWithDefaultPrettyPrinter().writeValue( output, node ); return output.toString( TextUtil.CHARSET ); } public static class ColorSerializer extends JsonSerializer<Color> { @Override public void serialize( Color value, JsonGenerator generator, SerializerProvider provider ) throws IOException { generator.writeString( value.toString() ); } } public static class Point2DSerializer extends JsonSerializer<Point2D> { @Override public void serialize( Point2D value, JsonGenerator generator, SerializerProvider provider ) throws IOException { generator.writeString( value.getX() + "," + value.getY() ); } } public static class Point3DSerializer extends JsonSerializer<Point3D> { @Override public void serialize( Point3D value, JsonGenerator generator, SerializerProvider provider ) throws IOException { generator.writeString( value.getX() + "," + value.getY() + "," + value.getZ() ); } } }
amygeek/computer-science-in-js
src/js/dynamicProgrammming/scoring-options.js
/** * Imagine a game (like baseball) where a player can score 1, 2 or 4 runs. Given a score "n", * find the total number of ways score "n" can be reached. Fibonacci Numbers Memoization S(n)=S(n−1)+S(n−2)+S(n−4) Runtime Complexity Linear, O(n). Memory Complexity Linear, O(n). we'll use the memoization technique. Memoization is an optimization technique used to make programs faster and improve their performance by storing the results of expensive function calls and returning the cached results when the same inputs occur again. It saves the computed results for possible later reuse, rather than recomputing them. The scoring options are 1, 2, 4. To find the number of ways a player can score 'n' runs, the recurrence relation is as follows: S(n) = S(n-1) + S(n-2) + S(n-4) n = 5 11111 1112 1121 1211 122 14 2111 212 221 41 */ let countScoreRec = function(n, res) { if (n < 0) { return 0; } if ( n === 0) { res[n] = 1; return res[n]; } if (res[n]) { return res[n]; } res[n] = countScoreRec(n - 1, res) + countScoreRec(n - 2, res) + countScoreRec(n - 4, res); return res[n]; }; let countScore = function(n) { if (n <= 0) { return 0; } let res = [...Array(n)]; return countScoreRec(n, res); }; console.log( countScore(4) ); //6 /** Runtime Complexity Linear, O(n). Memory Complexity Constant, O(1). In solution 2, we'll use the dynamic programming approach to build the solution bottom-up. We'll store the results in a fixed size array. Scoring options are 1, 2, 4. Maximum score is 4, so we need to save last four ways to calculate the number of ways for a given 'n'. On each iteration, the result will be the sum of values present at 3rd, 2nd and 0th index of the results array. This is because the result at 'n' is the sum of values at n-1, n-2 and n-4. We'll slide the results towards left and save the current result at the last index. */ let countScoreDp = function(n) { if (n <= 0) { return 0; } //Max score is 4. Hence we need to save //last 4 ways to calculate the number of ways //for a given n //save the base case on last index of the vector let res = [0, 0, 0, 1]; for (var i = 1; i <= n; i++) { let current = res[3] + res[2] + res[0]; //slide left all the results in each iteration //res for current i will be saved at last index res[0] = res[1]; res[1] = res[2]; res[2] = res[3]; res[3] = current; } return res[3]; }; console.log( countScoreDp(5) ); //10
pabigot/bsp430
examples/platform/cpu42/main.c
/** This file is in the public domain. * * This program demonstrates whether CPU erratum CPU42 is present on * the running chip. Note that BSP430 is not subject to this bug when * #BSP430_CORE_ENABLE_INTERRUPT() is used instead of the raw * __enable_interrupt(). * * @homepage http://github.com/pabigot/bsp430 * */ #include <bsp430/platform.h> #include <bsp430/clock.h> #include <bsp430/utility/console.h> #include <bsp430/utility/led.h> BSP430_CORE_DECLARE_INTERRUPT(PORT1_VECTOR) port_isr (void) { (void)P1IV; __delay_cycles(10000); } void main () { unsigned int t0; unsigned int t1; vBSP430platformInitialize_ni(); (void)iBSP430consoleInitialize(); cputs("\n\nCPU42 evaluator\n"); P1IE |= BIT0; P1IFG |= BIT0; TA0CTL = TASSEL_1 | MC_2 | TACLR; /* Synchronize on tick */ t0 = TA0R; while (t0 == TA0R) { ; } t0 = TA0R; t1 = TA0R; cprintf("DINT: Timer read %u %u delta %u\n", t0, t1, t1-t0); /* Synchronize on tick */ t0 = TA0R; while (t0 == TA0R) { ; } /* If CPU42 is present and __enable_interrupt() does not work around * it, the first read of TA0R will execute before the interrupt * handler that introduces a 10 kCycle delay, resulting in a large * difference between the values. */ __enable_interrupt(); t0 = TA0R; t1 = TA0R; cprintf("EINT: Timer read %u %u delta %u\n", t0, t1, t1-t0); if (1 < (t1-t0)) { vBSP430ledSet(BSP430_LED_RED, 1); cputs("CPU42 appears to be present\n"); } else { vBSP430ledSet(BSP430_LED_GREEN, 1); cputs("Unable to confirm presence of CPU42\n"); } }
Quorafind/GuiLiteSamples
HelloWave/BuildSTM32F429-Gcc/guiLite_stm32f429/song/antialiasing.c
<filename>HelloWave/BuildSTM32F429-Gcc/guiLite_stm32f429/song/antialiasing.c // // Created by song on 17-6-1. // #include "stdlib.h" #include "math.h" #include "antialiasing.h" #include "color.h" uint16_t ipart(double x) { return (uint16_t) x; } float fpart(float x) { return (float) (x - floor(x)); } float rfpart(float x) { return (float) (1.0 - fpart(x)); } void ltdc_aa_line(uint16_t x0, uint16_t y0, uint16_t x1, uint16_t y1, uint32_t color, uint32_t backcolor) { uint8_t steep = (uint8_t) (abs(y1 - y0) > abs(x1 - x0)); // if (steep) { // if (y0 > y1) { // ltdc_aa_line(x1, y1, x0, y0, color, backcolor); // } // } //// ltdc_aa_line(y0, x0, y1, x1, color, backcolor); // if (x0 > x1) // ltdc_aa_line(x1, y1, x0, y0, color, backcolor); uint16_t tmp; uint16_t tmp1; // if (steep) { // if (y0 > y1) { // tmp = x0; // x0 = x1; // x1 = tmp; // tmp1 = y0; // y0 = y1; // y1 = tmp1; // } // } else { // if (x0 > x1) { // // tmp = x0; // x0 = x1; // x1 = tmp; // tmp1 = y0; // y0 = y1; // y1 = tmp1; // } // } int16_t dx = (x1 - x0); int16_t dy = (y1 - y0); float gradient = 0; if (steep) { gradient = (float) ((1.0 * dx) / dy); } else { gradient = (float) ((1.0 * dy) / dx); } if (steep) { if (y0 < y1) { for (uint16_t i = y0; i < y1; ++i) { ltdc_draw_point_a(i, (int16_t) ipart(x0 + gradient * (i - y0)), colorBlend(color, backcolor, rfpart(x0 + gradient * (i - y0)))); ltdc_draw_point_a(i, (int16_t) (ipart(x0 + gradient * (i - y0)) + 1), colorBlend(color, backcolor, fpart(x0 + gradient * (i - y0)))); } } else { for (uint16_t i = y1; i < y0; ++i) { ltdc_draw_point_a(i, (int16_t) ipart(x1 + gradient * (i - y1)), colorBlend(color, backcolor, rfpart(x0 + gradient * (i - y1)))); ltdc_draw_point_a(i, (int16_t) (ipart(x1 + gradient * (i - y1)) + 1), colorBlend(color, backcolor, fpart(x1 + gradient * (i - y1)))); } } } else { if (x0 < x1) { for (uint16_t i = x0; i < x1; ++i) { ltdc_draw_point(i, (uint16_t) ipart(y0 + gradient * (i - x0)), colorBlend(color, backcolor, rfpart(y0 + gradient * (i - x0)))); ltdc_draw_point(i, (uint16_t) (ipart(y0 + gradient * (i - x0)) + 1), colorBlend(color, backcolor, fpart(y0 + gradient * (i - x0)))); } } else { for (uint16_t i = x1; i < x0; ++i) { ltdc_draw_point(i, (uint16_t) ipart(y1 + gradient * (i - x1)), colorBlend(color, backcolor, rfpart(y1 + gradient * (i - x1)))); ltdc_draw_point(i, (uint16_t) (ipart(y1 + gradient * (i - x1)) + 1), colorBlend(color, backcolor, fpart(y1 + gradient * (i - x1)))); } } } } //void DrawArch( int r ){ // int y=0; // int x=r; // float d=0; // ltdc_draw_point(x,y,A); // while( x>y ){ // y++; // if( DC(r,y) < d ) x--; // putpixel(x, y, A*(1-DC(R,y) ); // putpixel(x-1, y, A* DC(R,y) ); // d = DC(r,y); // } //} // ////Distance to ceil: //double DC(int r, int y){ // double x = sqrt(r*r-y*y); // return ceil(x) - x; //} void ltdc_aa_arc(uint16_t x0, uint16_t y0, uint16_t r1, uint16_t degFrom, uint16_t degTo, uint32_t color, uint32_t backcolor) { float x; float y; float f; float rf; float f1; float rf1; uint16_t xp1 = (uint16_t) floor(0.707 * r1); float g1 = (float) ((90 * 3.1416) / 180); float g2 = (float) ((89 * 3.1416) / 180); float gap = (cosf(g2) * r1 - cosf(g1) * r1); uint8_t am = (uint8_t) ceil(gap); for (uint16_t i = degFrom; i < degTo; ++i) { for (uint16_t j = 0; j < am; ++j) { float fi = (float) (i + 1.0 * j / am); float d = (float) ((fi * 3.1416) / 180); x = (cosf(d) * r1); y = (sinf(d) * r1); f = fpart(y0 - y); rf = rfpart(y0 - y); f1 = fpart(x + x0); rf1 = rfpart(x + x0); if ((x >= (-1 * xp1)) && (x <= xp1)) { if (y > 0) { ltdc_draw_point((uint16_t) (x0 + x), (uint16_t) (ipart(y0 - y)), colorBlend(color, backcolor, f)); ltdc_draw_point((uint16_t) (x0 + x), (uint16_t) (ipart(y0 - y) - 1), colorBlend(color, backcolor, rf)); } else { ltdc_draw_point((uint16_t) (x0 + x), (uint16_t) (ipart(y0 - y)), colorBlend(color, backcolor, rf)); ltdc_draw_point((uint16_t) (x0 + x), (uint16_t) ((ipart(y0 - y) + 1)), colorBlend(color, backcolor, f)); } } else { if (x > 0) { ltdc_draw_point_a((uint16_t) (y0 - y), (uint16_t) (ipart(x0 + x)), colorBlend(color, backcolor, rf1)); ltdc_draw_point_a((uint16_t) (y0 - y), (uint16_t) (ipart(x0 + x) + 1), colorBlend(color, backcolor, f1)); } else { ltdc_draw_point_a((uint16_t) (y0 - y), (uint16_t) (ipart(x + x0)), colorBlend(color, backcolor, f1)); ltdc_draw_point_a((uint16_t) (y0 - y), (uint16_t) (ipart(x + x0) - 1), colorBlend(color, backcolor, rf1)); } } } } } void ltdc_aa_farc(uint16_t x0, uint16_t y0, uint16_t r1, uint16_t degFrom, uint16_t degTo, uint32_t color, uint32_t backcolor) { ltdc_aa_arc(x0, y0, r1, degFrom, degTo, color, backcolor); uint16_t xstart = (uint16_t) (x0 + cosf((float) (degFrom * 3.1416 / 180)) * r1); uint16_t ystart = (uint16_t) (y0 - sinf((float) (degFrom * 3.1416 / 180)) * r1); uint16_t xend = (uint16_t) (x0 + cosf((float) (degTo * 3.1416 / 180)) * r1); uint16_t yend = (uint16_t) (y0 - sinf((float) (degTo * 3.1416 / 180)) * r1); ltdc_aa_line(x0, y0, xstart, ystart, color, backcolor); ltdc_aa_line(x0, y0, xend, yend, color, backcolor); float deg; for (int16_t i = (int16_t) (-1 * r1); i <= r1; ++i) { for (int16_t j = (int16_t) 0; j <= r1; ++j) { // ltdc_draw_point(i + x0, j + y0, R888T565(color)); if (((i * i + j * j) <= (r1 + 1) * (r1 + 1))) { deg = (float) ((asinf((float) ((j * 1.0) / sqrt(j * j + i * i))) * 180) / 3.1416); if (i < 0) { deg = 180 - deg; } if ((deg) > degFrom && deg < degTo) { ltdc_draw_point(i + x0, y0 - j, R888T565(color)); } } } } for (int16_t i = (int16_t) (-1 * r1); i <= r1; ++i) { for (int16_t j = (int16_t) (-1 * r1); j <= 0; ++j) { // delay_ms(30); if (i < 0 && j > -0.3 * r1) { if ((i * i + j * j) <= (r1 + 1) * (r1 + 1)) { deg = (float) ((asinf((float) ((j * 1.0) / sqrt(j * j + i * i))) * 180) / 3.1416); if (i < 0) { deg = 180 - deg; } if (deg < 0) { deg += 360; } if ((deg) > degFrom && deg < degTo) { ltdc_draw_point(i + x0, y0 - j, R888T565(color)); } } } else if ((i * i + j * j) <= (r1) * (r1)) { deg = (float) ((asinf((float) ((j * 1.0) / sqrt(j * j + i * i))) * 180) / 3.1416); if (i < 0) { deg = 180 - deg; } if (deg < 0) { deg += 360; } if ((deg) > degFrom && deg < degTo) { ltdc_draw_point(i + x0, y0 - j, R888T565(color)); } } } } } void ltdc_aa_ring(uint16_t x0, uint16_t y0, uint16_t r1, uint16_t r2, uint16_t degFrom, uint16_t degTo, uint32_t color, uint32_t backcolor) { ltdc_aa_arc(x0, y0, r1, degFrom, degTo, color, backcolor); ltdc_aa_arc(x0, y0, r2, degFrom, degTo, color, backcolor); uint16_t xstart = (uint16_t) (x0 + cosf((float) (degFrom * 3.1416 / 180)) * r1); uint16_t ystart = (uint16_t) (y0 - sinf((float) (degFrom * 3.1416 / 180)) * r1); uint16_t xend = (uint16_t) (x0 + cosf((float) (degTo * 3.1416 / 180)) * r1); uint16_t yend = (uint16_t) (y0 - sinf((float) (degTo * 3.1416 / 180)) * r1); float deg; for (int16_t i = (int16_t) (-1 * r1); i <= r1; ++i) { for (int16_t j = (int16_t) 0; j <= r1; ++j) { // ltdc_draw_point(i + x0, j + y0, R888T565(color)); if (((i * i + j * j) <= (r1 + 1) * (r1 + 1)) && ((i * i + j * j) >= (r2 + 1) * (r2 + 1))) { deg = (float) ((asinf((float) ((j * 1.0) / sqrt(j * j + i * i))) * 180) / 3.1416); if (i < 0) { deg = 180 - deg; } if ((deg) > degFrom && deg < degTo) { ltdc_draw_point(i + x0, y0 - j, R888T565(color)); } } } } for (int16_t i = (int16_t) (-1 * r1); i <= r1; ++i) { for (int16_t j = (int16_t) (-1 * r1); j <= 0; ++j) { // delay_ms(30); if (i < 0 && j > -0.3 * r1) { if (((i * i + j * j) <= (r1 + 1) * (r1 + 1)) && ((i * i + j * j) >= (r2 + 1) * (r2 + 1))) { deg = (float) ((asinf((float) ((j * 1.0) / sqrt(j * j + i * i))) * 180) / 3.1416); if (i < 0) { deg = 180 - deg; } if (deg < 0) { deg += 360; } if ((deg) > degFrom && deg < degTo) { ltdc_draw_point(i + x0, y0 - j, R888T565(color)); } } } else if (((i * i + j * j) <= (r1) * (r1)) && ((i * i + j * j) >= (r2) * (r2))) { deg = (float) ((asinf((float) ((j * 1.0) / sqrt(j * j + i * i))) * 180) / 3.1416); if (i < 0) { deg = 180 - deg; } if (deg < 0) { deg += 360; } if ((deg) > degFrom && deg < degTo) { ltdc_draw_point(i + x0, y0 - j, R888T565(color)); } } } } } uint16_t max(uint16_t x0, uint16_t x1) { if (x0 > x1) return x0; else return x1; } uint16_t min(uint16_t x0, uint16_t x1) { if (x0 < x1) return x0; else return x1; }
stIncMale/ratmex
ratmex/src/main/java/stincmale/ratmex/executor/RateMeasuringExecutorService.java
<filename>ratmex/src/main/java/stincmale/ratmex/executor/RateMeasuringExecutorService.java<gh_stars>0 /* * Copyright 2017-2018 <NAME> * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package stincmale.ratmex.executor; import java.util.concurrent.ExecutionException; import java.util.concurrent.ExecutorService; import java.util.concurrent.Future; import java.util.concurrent.RejectedExecutionException; import java.util.concurrent.ScheduledExecutorService; import java.util.concurrent.ScheduledFuture; import java.util.concurrent.TimeUnit; import stincmale.ratmex.doc.ThreadSafe; import stincmale.ratmex.executor.config.ScheduledTaskConfig; import stincmale.ratmex.executor.listener.RateListener; import stincmale.ratmex.executor.listener.RateMeasuredEvent; /** * A rate-measuring executor service which not only executes tasks with a fixed {@link Rate rate}, * but also measures the actual rate completion of the tasks * and allows one to {@linkplain RateListener monitor the rate and react} if the executor has failed to conform to the target rate. * <p> * <b>The reasoning behind {@link RateMeasuringExecutorService}</b><br> * The functionality described by this interface cannot be directly obtained from * {@link ScheduledExecutorService#scheduleAtFixedRate(Runnable, long, long, TimeUnit)}, which says the following regarding the task being scheduled: * <i>"If any execution of this task takes longer than its period, then subsequent executions may start late, but will not concurrently execute"</i>. * This tells us that: * <ul> * <li>{@link ScheduledExecutorService} is allowed to execute tasks with a lower rate than the target (and there is no easy way to check).</li> * <li>{@link ScheduledExecutorService} executes a scheduled task serially, which means that you cannot easily benefit from multithreading, * and the rate is heavily limited by the time the task takes to complete.</li> * </ul> * {@link RateMeasuringExecutorService} overcomes both of the above points. * * @param <C> A type of scheduled task config used in {@link #scheduleAtFixedRate(Runnable, Rate, C)}. * @param <E> A type of container with data provided to a {@linkplain ScheduledTaskConfig#getRateListenerSupplier() rate listener}. */ @ThreadSafe public interface RateMeasuringExecutorService<C extends ScheduledTaskConfig<? extends E>, E extends RateMeasuredEvent> extends ExecutorService, AutoCloseable { /** * Schedules a {@code task} to be executed with a fixed {@code rate}. * <p> * The repeated execution of the {@code task} continues indefinitely until * one of the following exceptional completions occur: * <ul> * <li>The task is {@linkplain Future#cancel(boolean) explicitly cancelled} via the returned future.</li> * <li>The executor {@linkplain #isTerminated() terminates}, also resulting in task {@linkplain Future#cancel(boolean) cancellation}.</li> * <li>An execution of the task throws a {@link RuntimeException}. * In this case calling {@link Future#get() get()} on the returned future will throw {@link ExecutionException}.</li> * <li>The scheduled task {@linkplain ScheduledTaskConfig#getDuration() times out}.</li> * <li>The {@linkplain ScheduledTaskConfig#getRateListenerSupplier() rate listener}'s method * {@link RateListener#onMeasurement(RateMeasuredEvent)} returns false, * also resulting in task {@linkplain Future#cancel(boolean) cancellation}.</li> * </ul> * Subsequent executions are suppressed. Subsequent calls to {@link Future#isDone isDone()} on the returned future will return {@code true}. * * @param task A task to schedule for repetitive execution. Must not be {@code null}. * @param targetRate A target rate of completion of the task executions. Must not be {@code null}. * @param config An additional configuration. Must not be {@code null}. * * @return A {@link ScheduledFuture} representing pending completion of the {@code task}. * The future's {@link Future#get() get()} method will never return normally, * and will throw an exception upon task cancellation or abnormal termination of a task execution. * * @throws RejectedExecutionException If the task cannot be scheduled for execution. */ ScheduledFuture<?> scheduleAtFixedRate(Runnable task, Rate targetRate, C config) throws RejectedExecutionException; /** * This method is equivalent to calling {@link #shutdownNow()}. * Subclasses may extend this behaviour, but must always call {@link #shutdownNow()}. */ @Override default void close() { shutdownNow(); } }
504479518/spring-cloud-parent
caesar-admin/admin-boot/src/main/java/com/caesar/admin/service/ISysRoleMenuService.java
package com.caesar.admin.service; import com.baomidou.mybatisplus.extension.service.IService; import com.caesar.admin.pojo.entity.SysRoleMenu; import java.util.List; /** * @author caesar * @desc 角色菜单 * @email <EMAIL> * @date 2021/12/2 */ public interface ISysRoleMenuService extends IService<SysRoleMenu> { List<Long> listMenuIds(Long roleId); /** * 修改角色菜单 * * @param roleId * @param menuIds * @return */ boolean update(Long roleId, List<Long> menuIds); }
Loks-/competitions
hackerrank/practice/mathematics/number_theory/superpowers_of_2.cpp
<filename>hackerrank/practice/mathematics/number_theory/superpowers_of_2.cpp // https://www.hackerrank.com/challenges/superpowers #include "common/factorization/utils/eulers_totient.h" #include "common/factorization/utils/factorization_base.h" #include "common/modular/arithmetic.h" #include "common/modular/utils/merge_remainders.h" #include "common/stl/base.h" using TModularA = modular::TArithmetic_C32U; int main_superpowers_of_2() { uint64_t a, b, c = 1, d, r, one = 1; cin >> a >> b; if (b <= 2) { r = 0; } else if (a < 61) { r = TModularA::PowUSafe(2, (one << a), b); } else { for (; (b & 1) == 0; b /= 2) c *= 2; d = EulersTotient(b, FactorizeBase(b)); uint64_t aa = TModularA::PowUSafe(2, a, d); r = MergeRemainders<TModularA>(c, 0, b, TModularA::PowUSafe(2, aa, b)); } cout << r << endl; return 0; }
chromium/chromium
build/lacros/mojo_connection_lacros_launcher.py
<reponame>chromium/chromium<filename>build/lacros/mojo_connection_lacros_launcher.py #!/usr/bin/env vpython3 # # Copyright 2020 The Chromium Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. """Helps launch lacros-chrome with mojo connection established on Linux or Chrome OS. Use on Chrome OS is for dev purposes. The main use case is to be able to launch lacros-chrome in a debugger. Please first launch an ash-chrome in the background as usual except without the '--lacros-chrome-path' argument and with an additional '--lacros-mojo-socket-for-testing' argument pointing to a socket path: XDG_RUNTIME_DIR=/tmp/ash_chrome_xdg_runtime ./out/ash/chrome \\ --user-data-dir=/tmp/ash-chrome --enable-wayland-server \\ --no-startup-window --enable-features=LacrosSupport \\ --lacros-mojo-socket-for-testing=/tmp/lacros.sock Then, run this script with '-s' pointing to the same socket path used to launch ash-chrome, followed by a command one would use to launch lacros-chrome inside a debugger: EGL_PLATFORM=surfaceless XDG_RUNTIME_DIR=/tmp/ash_chrome_xdg_runtime \\ ./build/lacros/mojo_connection_lacros_launcher.py -s /tmp/lacros.sock gdb --args ./out/lacros-release/chrome --user-data-dir=/tmp/lacros-chrome """ import argparse import array import contextlib import getpass import grp import os import pathlib import pwd import resource import socket import sys import subprocess _NUM_FDS_MAX = 3 # contextlib.nullcontext is introduced in 3.7, while Python version on # CrOS is still 3.6. This is for backward compatibility. class NullContext: def __init__(self, enter_ret=None): self.enter_ret = enter_ret def __enter__(self): return self.enter_ret def __exit__(self, exc_type, exc_value, trace): pass def _ReceiveFDs(sock): """Receives FDs from ash-chrome that will be used to launch lacros-chrome. Args: sock: A connected unix domain socket. Returns: File objects for the mojo connection and maybe startup data file. """ # This function is borrowed from with modifications: # https://docs.python.org/3/library/socket.html#socket.socket.recvmsg fds = array.array("i") # Array of ints # Along with the file descriptor, ash-chrome also sends the version in the # regular data. version, ancdata, _, _ = sock.recvmsg( 1, socket.CMSG_LEN(fds.itemsize * _NUM_FDS_MAX)) for cmsg_level, cmsg_type, cmsg_data in ancdata: if cmsg_level == socket.SOL_SOCKET and cmsg_type == socket.SCM_RIGHTS: # There are three versions currently this script supports. # The oldest one: ash-chrome returns one FD, the mojo connection of # old bootstrap procedure (i.e., it will be BrowserService). # The middle one: ash-chrome returns two FDs, the mojo connection of # old bootstrap procedure, and the second for the start up data FD. # The newest one: ash-chrome returns three FDs, the mojo connection of # old bootstrap procedure, the second for the start up data FD, and # the third for another mojo connection of new bootstrap procedure. # TODO(crbug.com/1156033): Clean up the code to drop the support of # oldest one after M91. # TODO(crbug.com/1180712): Clean up the mojo procedure support of the # the middle one after M92. cmsg_len_candidates = [(i + 1) * fds.itemsize for i in range(_NUM_FDS_MAX)] assert len(cmsg_data) in cmsg_len_candidates, ( 'CMSG_LEN is unexpected: %d' % (len(cmsg_data), )) fds.frombytes(cmsg_data[:]) if version == b'\x00': assert len(fds) in (1, 2, 3), 'Expecting exactly 1, 2, or 3 FDs' legacy_mojo_fd = os.fdopen(fds[0]) startup_fd = None if len(fds) < 2 else os.fdopen(fds[1]) mojo_fd = None if len(fds) < 3 else os.fdopen(fds[2]) elif version == b'\x01': assert len(fds) == 2, 'Expecting exactly 2 FDs' legacy_mojo_fd = None startup_fd = os.fdopen(fds[0]) mojo_fd = os.fdopen(fds[1]) else: raise AssertionError('Unknown version: \\x%s' % version.encode('hex')) return legacy_mojo_fd, startup_fd, mojo_fd def _MaybeClosing(fileobj): """Returns closing context manager, if given fileobj is not None. If the given fileobj is none, return nullcontext. """ return (contextlib.closing if fileobj else NullContext)(fileobj) def _ApplyCgroups(): """Applies cgroups used in ChromeOS to lacros chrome as well.""" # Cgroup directories taken from ChromeOS session_manager job configuration. UI_FREEZER_CGROUP_DIR = '/sys/fs/cgroup/freezer/ui' UI_CPU_CGROUP_DIR = '/sys/fs/cgroup/cpu/ui' pid = os.getpid() with open(os.path.join(UI_CPU_CGROUP_DIR, 'tasks'), 'a') as f: f.write(str(pid) + '\n') with open(os.path.join(UI_FREEZER_CGROUP_DIR, 'cgroup.procs'), 'a') as f: f.write(str(pid) + '\n') def _PreExec(uid, gid, groups): """Set environment up for running the chrome binary.""" # Nice and realtime priority values taken ChromeOSs session_manager job # configuration. resource.setrlimit(resource.RLIMIT_NICE, (40, 40)) resource.setrlimit(resource.RLIMIT_RTPRIO, (10, 10)) os.setgroups(groups) os.setgid(gid) os.setuid(uid) def Main(): arg_parser = argparse.ArgumentParser() arg_parser.usage = __doc__ arg_parser.add_argument( '-r', '--root-env-setup', action='store_true', help='Set typical cgroups and environment for chrome. ' 'If this is set, this script must be run as root.') arg_parser.add_argument( '-s', '--socket-path', type=pathlib.Path, required=True, help='Absolute path to the socket that were used to start ash-chrome, ' 'for example: "/tmp/lacros.socket"') flags, args = arg_parser.parse_known_args() assert 'XDG_RUNTIME_DIR' in os.environ assert os.environ.get('EGL_PLATFORM') == 'surfaceless' if flags.root_env_setup: # Check if we are actually root and error otherwise. assert getpass.getuser() == 'root', \ 'Root required environment flag specified, but user is not root.' # Apply necessary cgroups to our own process, so they will be inherited by # lacros chrome. _ApplyCgroups() else: print('WARNING: Running chrome without appropriate environment. ' 'This may affect performance test results. ' 'Set -r and run as root to avoid this.') with socket.socket(socket.AF_UNIX, socket.SOCK_STREAM) as sock: sock.connect(flags.socket_path.as_posix()) legacy_mojo_connection, startup_connection, mojo_connection = ( _ReceiveFDs(sock)) with _MaybeClosing(legacy_mojo_connection), \ _MaybeClosing(startup_connection), \ _MaybeClosing(mojo_connection): cmd = args[:] pass_fds = [] if legacy_mojo_connection: cmd.append('--mojo-platform-channel-handle=%d' % legacy_mojo_connection.fileno()) pass_fds.append(legacy_mojo_connection.fileno()) else: # TODO(crbug.com/1188020): This is for backward compatibility. # We should remove this after M93 lacros is spread enough. cmd.append('--mojo-platform-channel-handle=-1') if startup_connection: cmd.append('--cros-startup-data-fd=%d' % startup_connection.fileno()) pass_fds.append(startup_connection.fileno()) if mojo_connection: cmd.append('--crosapi-mojo-platform-channel-handle=%d' % mojo_connection.fileno()) pass_fds.append(mojo_connection.fileno()) env = os.environ.copy() if flags.root_env_setup: username = 'chronos' p = pwd.getpwnam(username) uid = p.pw_uid gid = p.pw_gid groups = [g.gr_gid for g in grp.getgrall() if username in g.gr_mem] env['HOME'] = p.pw_dir env['LOGNAME'] = username env['USER'] = username def fn(): return _PreExec(uid, gid, groups) else: def fn(): return None proc = subprocess.Popen(cmd, pass_fds=pass_fds, preexec_fn=fn) return proc.wait() if __name__ == '__main__': sys.exit(Main())
lleohao/NEJ-ES6
src/nejRoot/util/dispatcher/dsp/node.js
<gh_stars>1-10 /* * ------------------------------------------ * 树节点对象实现文件 * @version 1.0 * @author genify(caijf) * ------------------------------------------ */ /** @module util/dispatcher/dsp/node */ NEJ.define([ 'base/global', 'base/klass', 'base/util', 'util/event' ],function(NEJ,_k,_u,_t,_p,_o,_f,_r){ var _pro; /** * 树节点对象 * * 脚本举例 * ```javascript * NEJ.define([ * 'util/dispatcher/dsp/node' * ],function(_p){ * // ___ * // |_/_| <-- 节点名称为"/"的节点 * // / \ * // _/_ _\_ * // |_a_| |_b_| <-- 节点名称为"b"的节点 * * // 分配一个名称为“/”的节点 * var _root = _p._$$Node._$allocate(); * * // 分配一个名称为“a”的节点,并指定父节点为_root * var _node = _p._$$Node._$allocate({ * parent:_root, * name:'a' * }); * * // 分配一个名称为“b”的节点,手动设置父节点 * var _node = _$$Node._$allocate({ * name:'b' * }); * _node._$setParent(_root); * * // 回收树,同时回收节点的所有子孙节点 * _root = _root._$recycle(); * }); * ``` * * @class module:util/dispatcher/dsp/node._$$Node * @extends module:util/event._$$EventTarget * * @param {Object} config - 可选配置参数 * @property {_$$Node} parent - 父节点 * @property {String} name - 节点名称,默认为"/" * @property {Object} data - 节点缓存的数据信息 */ _p._$$Node = _k._$klass(); _pro = _p._$$Node._$extend(_t._$$EventTarget); /** * 控件初始化 * * @protected * @method module:util/dispatcher/dsp/node._$$Node#__init * @return {Void} */ _pro.__init = function(){ this.__super(); this.__children = []; }; /** * 控件重置 * * @protected * @method module:util/dispatcher/dsp/node._$$Node#__reset * @param {Object} arg0 - 可选配置参数 * @return {Void} */ _pro.__reset = function(_options){ this.__super(_options); this._$setParent(_options.parent); this.__name = _options.name||'/'; this.__data = _options.data||{}; }; /** * 控件销毁 * * @protected * @method module:util/dispatcher/dsp/node._$$Node#__destroy * @return {Void} */ _pro.__destroy = (function(){ var _doRecycle = function(_node,_index,_list){ _list.splice(_index,1); _node._$recycle(); }; return function(){ this.__super(); delete this.__data; _u._$reverseEach( this.__children, _doRecycle ); this._$setParent(null); }; })(); /** * 是否节点实例 * * @protected * @method module:util/dispatcher/dsp/node._$$Node#__isNode * @param {module:util/dispatcher/dsp/node._$$Node} arg0 - 节点 * @return {Boolean} 是否节点实例 */ _pro.__isNode = function(_node){ return _node instanceof this.constructor; }; /** * 是否有子节点 * * @protected * @method module:util/dispatcher/dsp/node._$$Node#__hasChild * @param {module:util/dispatcher/dsp/node._$$Node} arg0 - 子节点 * @return {Boolean} 是否有子节点 */ _pro.__hasChild = function(_child){ return _u._$indexOf(this.__children,_child)>=0; }; /** * 取节点名称 * * @method module:util/dispatcher/dsp/node._$$Node#_$getName * @return {String} 节点名称 */ _pro._$getName = function(){ return this.__name; }; /** * 取节点保存的信息 * * @method module:util/dispatcher/dsp/node._$$Node#_$getData * @return {Object} 数据信息 */ _pro._$getData = function(){ return this.__data; }; /** * 取当前节点路径 * * @method module:util/dispatcher/dsp/node._$$Node#_$getPath * @return {String} 路径 */ _pro._$getPath = function(){ var _parent = this._$getParent(), _name = this._$getName(); if (!_parent) return _name; var _pname = _parent._$getName(); if (_pname!='/'&&_name!='/') _name = '/'+_name; return _parent._$getPath()+_name; }; /** * 取父节点 * * @method module:util/dispatcher/dsp/node._$$Node#_$getParent * @return {_$$Node} 父节点 */ _pro._$getParent = function(){ return this.__parent; }; /** * 取子节点列表 * * @method module:util/dispatcher/dsp/node._$$Node#_$getChildren * @return {Array} 子节点列表 */ _pro._$getChildren = function(){ return this.__children; }; /** * 取指定名称的子节点 * * @method module:util/dispatcher/dsp/node._$$Node#_$getChildByName * @param {String} arg0 - 名称 * @return {module:util/dispatcher/dsp/node._$$Node} 子节点 */ _pro._$getChildByName = function(_name){ var _index = _u._$indexOf( this.__children,function(_node){ return _name==_node._$getName(); } ); return this.__children[_index]||null; }; /** * 设置父节点 * * @method module:util/dispatcher/dsp/node._$$Node#_$setParent * @param {module:util/dispatcher/dsp/node._$$Node} arg0 - 父节点 * @return {Void} */ _pro._$setParent = function(_parent){ _parent = this.__isNode(_parent)?_parent:null; if (_parent==this.__parent) return; !!_parent ? _parent._$appendChild(this) : this.__parent._$removeChild(this); this.__parent = _parent; }; /** * 添加子节点 * * @method module:util/dispatcher/dsp/node._$$Node#_$appendChild * @param {module:util/dispatcher/dsp/node._$$Node} arg0 - 子节点 * @return {Void} */ _pro._$appendChild = function(_child){ _child = this.__isNode(_child)?_child:null; if (!_child||this.__hasChild(_child)) return; this.__children.push(_child); _child._$setParent(this); }; /** * 删除子节点 * * @method module:util/dispatcher/dsp/node._$$Node#_$removeChild * @param {module:util/dispatcher/dsp/node._$$Node} arg0 - 子节点 * @return {module:util/dispatcher/dsp/node._$$Node} 删除的节点 */ _pro._$removeChild = function(_child){ _child = this.__isNode(_child)?_child:null; var _index = _u._$indexOf(this.__children,_child); if (_index>=0){ this.__children.splice(_index,1); _child._$setParent(null); } return _child; }; return _p; });
mdheller/rletters
app/lib/r_letters/analysis/stop_list.rb
<reponame>mdheller/rletters # frozen_string_literal: true module RLetters module Analysis # Code for parsing and loading lists of stop words class StopList # Return list of available stop lists # # @return [Hash<Symbol, Array<String>>] all present stop lists def self.available file_list = Rails.root.join('app', 'lib', 'r_letters', 'analysis', 'stop_list', 'stopwords_*.txt') [].tap do |ret| Dir[file_list].each do |filename| # Extract the language base = File.basename(filename) m = /stopwords_(..)\.txt/.match(base) ret << m[1].to_sym end end end # Return the stop list for the requested language # # @param [Symbol] lang language to request # @return [Array<String>] stop words for this language def self.for(lang) filename = Rails.root.join('app', 'lib', 'r_letters', 'analysis', 'stop_list', "stopwords_#{lang}.txt") return nil unless File.exist?(filename) [].tap do |ret| File.open(filename).each_line do |line| next if line == '' # Both hashes and pipes are used as comments in these files keep = line.split('|')[0] next if keep == '' keep = keep.split('#')[0] next if keep == '' # There might be more than one word per line, so take care of that words = keep.strip.split(' ') next if words.empty? ret.append(*words) end end end end end end
ca1e/gonx
services/nv/types.go
package nv type Layout uint8 type DisplayScanFormat uint8 type Kind uint8 type ColorFormat uint64 const ( LayoutPitch Layout = 1 LayoutTiled Layout = 2 LayoutBlockLinear Layout = 3 ) const ( DisplayScanFormatProgressive DisplayScanFormat = 0 DisplayScanFormatInterlaced DisplayScanFormat = 1 ) const ( KindPitch Kind = 0x0 KindZ16 Kind = 0x1 KindZ162C Kind = 0x2 KindZ16MS22C Kind = 0x3 KindZ16MS42C Kind = 0x4 KindZ16MS82C Kind = 0x5 KindZ16MS162C Kind = 0x6 KindZ162Z Kind = 0x7 KindZ16MS22Z Kind = 0x8 KindZ16MS42Z Kind = 0x9 KindZ16MS82Z Kind = 0xa KindZ16MS162Z Kind = 0xb KindZ164CZ Kind = 0xc KindZ16MS24CZ Kind = 0xd KindZ16MS44CZ Kind = 0xe KindZ16MS84CZ Kind = 0xf KindZ16MS164CZ Kind = 0x10 KindS8Z24 Kind = 0x11 KindS8Z241Z Kind = 0x12 KindS8Z24MS21Z Kind = 0x13 KindS8Z24MS41Z Kind = 0x14 KindS8Z24MS81Z Kind = 0x15 KindS8Z24MS161Z Kind = 0x16 KindS8Z242CZ Kind = 0x17 KindS8Z24MS22CZ Kind = 0x18 KindS8Z24MS42CZ Kind = 0x19 KindS8Z24MS82CZ Kind = 0x1a KindS8Z24MS162CZ Kind = 0x1b KindS8Z242CS Kind = 0x1C KindS8Z24MS22CS Kind = 0x1d KindS8Z24MS42CS Kind = 0x1e KindS8Z24MS82CS Kind = 0x1f KindS8Z24MS162CS Kind = 0x20 KindS8Z244CSZV Kind = 0x21 KindS8Z24MS24CSZV Kind = 0x22 KindS8Z24MS44CSZV Kind = 0x23 KindS8Z24MS84CSZV Kind = 0x24 KindS8Z24MS164CSZV Kind = 0x25 KindV8Z24MS4VC12 Kind = 0x26 KindV8Z24MS4VC4 Kind = 0x27 KindV8Z24MS8VC8 Kind = 0x28 KindV8Z24MS8VC24 Kind = 0x29 KindS8 Kind = 0x2a KindS82S Kind = 0x2b KindV8Z24MS4VC121ZV Kind = 0x2e KindV8Z24MS4VC41ZV Kind = 0x2f KindV8Z24MS8VC81ZV Kind = 0x30 KindV8Z24MS8VC241ZV Kind = 0x31 KindV8Z24MS4VC122CS Kind = 0x32 KindV8Z24MS4VC42CS Kind = 0x33 KindV8Z24MS8VC82CS Kind = 0x34 KindV8Z24MS8VC242CS Kind = 0x35 KindV8Z24MS4VC122CZV Kind = 0x3a KindV8Z24MS4VC42CZV Kind = 0x3b KindV8Z24MS8VC82CZV Kind = 0x3c KindV8Z24MS8VC242CZV Kind = 0x3d KindV8Z24MS4VC122ZV Kind = 0x3e KindV8Z24MS4VC42ZV Kind = 0x3f KindV8Z24MS8VC82ZV Kind = 0x40 KindV8Z24MS8VC242ZV Kind = 0x41 KindV8Z24MS4VC124CSZV Kind = 0x42 KindV8Z24MS4VC44CSZV Kind = 0x43 KindV8Z24MS8VC84CSZV Kind = 0x44 KindV8Z24MS8VC244CSZV Kind = 0x45 KindZ24S8 Kind = 0x46 KindZ24S81Z Kind = 0x47 KindZ24S8MS21Z Kind = 0x48 KindZ24S8MS41Z Kind = 0x49 KindZ24S8MS81Z Kind = 0x4a KindZ24S8MS161Z Kind = 0x4b KindZ24S82CS Kind = 0x4c KindZ24S8MS22CS Kind = 0x4d KindZ24S8MS42CS Kind = 0x4e KindZ24S8MS82CS Kind = 0x4f KindZ24S8MS162CS Kind = 0x50 KindZ24S82CZ Kind = 0x51 KindZ24S8MS22CZ Kind = 0x52 KindZ24S8MS42CZ Kind = 0x53 KindZ24S8MS82CZ Kind = 0x54 KindZ24S8MS162CZ Kind = 0x55 KindZ24S84CSZV Kind = 0x56 KindZ24S8MS24CSZV Kind = 0x57 KindZ24S8MS44CSZV Kind = 0x58 KindZ24S8MS84CSZV Kind = 0x59 KindZ24S8MS164CSZV Kind = 0x5a KindZ24V8MS4VC12 Kind = 0x5b KindZ24V8MS4VC4 Kind = 0x5C KindZ24V8MS8VC8 Kind = 0x5d KindZ24V8MS8VC24 Kind = 0x5e KindZ24V8MS4VC121ZV Kind = 0x63 KindZ24V8MS4VC41ZV Kind = 0x64 KindZ24V8MS8VC81ZV Kind = 0x65 KindZ24V8MS8VC241ZV Kind = 0x66 KindZ24V8MS4VC122CS Kind = 0x67 KindZ24V8MS4VC42CS Kind = 0x68 KindZ24V8MS8VC82CS Kind = 0x69 KindZ24V8MS8VC242CS Kind = 0x6a KindZ24V8MS4VC122CZV Kind = 0x6f KindZ24V8MS4VC42CZV Kind = 0x70 KindZ24V8MS8VC82CZV Kind = 0x71 KindZ24V8MS8VC242CZV Kind = 0x72 KindZ24V8MS4VC122ZV Kind = 0x73 KindZ24V8MS4VC42ZV Kind = 0x74 KindZ24V8MS8VC82ZV Kind = 0x75 KindZ24V8MS8VC242ZV Kind = 0x76 KindZ24V8MS4VC124CSZV Kind = 0x77 KindZ24V8MS4VC44CSZV Kind = 0x78 KindZ24V8MS8VC84CSZV Kind = 0x79 KindZ24V8MS8VC244CSZV Kind = 0x7a KindZF32 Kind = 0x7b KindZF321Z Kind = 0x7C KindZF32MS21Z Kind = 0x7d KindZF32MS41Z Kind = 0x7e KindZF32MS81Z Kind = 0x7f KindZF32MS161Z Kind = 0x80 KindZF322CS Kind = 0x81 KindZF32MS22CS Kind = 0x82 KindZF32MS42CS Kind = 0x83 KindZF32MS82CS Kind = 0x84 KindZF32MS162CS Kind = 0x85 KindZF322CZ Kind = 0x86 KindZF32MS22CZ Kind = 0x87 KindZF32MS42CZ Kind = 0x88 KindZF32MS82CZ Kind = 0x89 KindZF32MS162CZ Kind = 0x8a KindX8Z24X16V8S8MS4VC12 Kind = 0x8b KindX8Z24X16V8S8MS4VC4 Kind = 0x8c KindX8Z24X16V8S8MS8VC8 Kind = 0x8d KindX8Z24X16V8S8MS8VC24 Kind = 0x8e KindX8Z24X16V8S8MS4VC121CS Kind = 0x8f KindX8Z24X16V8S8MS4VC41CS Kind = 0x90 KindX8Z24X16V8S8MS8VC81CS Kind = 0x91 KindX8Z24X16V8S8MS8VC241CS Kind = 0x92 KindX8Z24X16V8S8MS4VC121ZV Kind = 0x97 KindX8Z24X16V8S8MS4VC41ZV Kind = 0x98 KindX8Z24X16V8S8MS8VC81ZV Kind = 0x99 KindX8Z24X16V8S8MS8VC241ZV Kind = 0x9a KindX8Z24X16V8S8MS4VC121CZV Kind = 0x9b KindX8Z24X16V8S8MS4VC41CZV Kind = 0x9c KindX8Z24X16V8S8MS8VC81CZV Kind = 0x9d KindX8Z24X16V8S8MS8VC241CZV Kind = 0x9e KindX8Z24X16V8S8MS4VC122CS Kind = 0x9f KindX8Z24X16V8S8MS4VC42CS Kind = 0xa0 KindX8Z24X16V8S8MS8VC82CS Kind = 0xa1 KindX8Z24X16V8S8MS8VC242CS Kind = 0xa2 KindX8Z24X16V8S8MS4VC122CSZV Kind = 0xa3 KindX8Z24X16V8S8MS4VC42CSZV Kind = 0xa4 KindX8Z24X16V8S8MS8VC82CSZV Kind = 0xa5 KindX8Z24X16V8S8MS8VC242CSZV Kind = 0xa6 KindZF32X16V8S8MS4VC12 Kind = 0xa7 KindZF32X16V8S8MS4VC4 Kind = 0xa8 KindZF32X16V8S8MS8VC8 Kind = 0xa9 KindZF32X16V8S8MS8VC24 Kind = 0xaa KindZF32X16V8S8MS4VC121CS Kind = 0xab KindZF32X16V8S8MS4VC41CS Kind = 0xac KindZF32X16V8S8MS8VC81CS Kind = 0xad KindZF32X16V8S8MS8VC241CS Kind = 0xae KindZF32X16V8S8MS4VC121ZV Kind = 0xb3 KindZF32X16V8S8MS4VC41ZV Kind = 0xb4 KindZF32X16V8S8MS8VC81ZV Kind = 0xb5 KindZF32X16V8S8MS8VC241ZV Kind = 0xb6 KindZF32X16V8S8MS4VC121CZV Kind = 0xb7 KindZF32X16V8S8MS4VC41CZV Kind = 0xb8 KindZF32X16V8S8MS8VC81CZV Kind = 0xb9 KindZF32X16V8S8MS8VC241CZV Kind = 0xba KindZF32X16V8S8MS4VC122CS Kind = 0xbb KindZF32X16V8S8MS4VC42CS Kind = 0xbc KindZF32X16V8S8MS8VC82CS Kind = 0xbd KindZF32X16V8S8MS8VC242CS Kind = 0xbe KindZF32X16V8S8MS4VC122CSZV Kind = 0xbf KindZF32X16V8S8MS4VC42CSZV Kind = 0xc0 KindZF32X16V8S8MS8VC82CSZV Kind = 0xc1 KindZF32X16V8S8MS8VC242CSZV Kind = 0xc2 KindZF32X24S8 Kind = 0xc3 KindZF32X24S81CS Kind = 0xc4 KindZF32X24S8MS21CS Kind = 0xc5 KindZF32X24S8MS41CS Kind = 0xc6 KindZF32X24S8MS81CS Kind = 0xc7 KindZF32X24S8MS161CS Kind = 0xc8 KindSmskedMessage Kind = 0xca KindSmhostMessage Kind = 0xcb KindC64MS22CRA Kind = 0xcd KindZF32X24S82CSZV Kind = 0xce KindZF32X24S8MS22CSZV Kind = 0xcf KindZF32X24S8MS42CSZV Kind = 0xd0 KindZF32X24S8MS82CSZV Kind = 0xd1 KindZF32X24S8MS162CSZV Kind = 0xd2 KindZF32X24S82CS Kind = 0xd3 KindZF32X24S8MS22CS Kind = 0xd4 KindZF32X24S8MS42CS Kind = 0xd5 KindZF32X24S8MS82CS Kind = 0xd6 KindZF32X24S8MS162CS Kind = 0xd7 KindC322C Kind = 0xd8 KindC322CBR Kind = 0xd9 KindC322CBA Kind = 0xda KindC322CRA Kind = 0xdb KindC322BRA Kind = 0xdc KindC32MS22C Kind = 0xdd KindC32MS22CBR Kind = 0xde KindC32MS22CRA Kind = 0xcc KindC32MS42C Kind = 0xdf KindC32MS42CBR Kind = 0xe0 KindC32MS42CBA Kind = 0xe1 KindC32MS42CRA Kind = 0xe2 KindC32MS42BRA Kind = 0xe3 KindC32MS8MS162C Kind = 0xe4 KindC32MS8MS162CRA Kind = 0xe5 KindC642C Kind = 0xe6 KindC642CBR Kind = 0xe7 KindC642CBA Kind = 0xe8 KindC642CRA Kind = 0xe9 KindC642BRA Kind = 0xea KindC64MS22C Kind = 0xeb KindC64MS22CBR Kind = 0xec KindC64MS42C Kind = 0xed KindC64MS42CBR Kind = 0xee KindC64MS42CBA Kind = 0xef KindC64MS42CRA Kind = 0xf0 KindC64MS42BRA Kind = 0xf1 KindC64MS8MS162C Kind = 0xf2 KindC64MS8MS162CRA Kind = 0xf3 KindC1282C Kind = 0xf4 KindC1282CR Kind = 0xf5 KindC128MS22C Kind = 0xf6 KindC128MS22CR Kind = 0xf7 KindC128MS42C Kind = 0xf8 KindC128MS42CR Kind = 0xf9 KindC128MS8MS162C Kind = 0xfa KindC128MS8MS162CR Kind = 0xfb KindX8C24 Kind = 0xfc KindPitchNoSwizzle Kind = 0xfd KindGeneric16BX2 Kind = 0xfe KindInvalid Kind = 0xff ) const ( ColorFormat_Unspecified ColorFormat = 0x0000000000 ColorFormat_NonColor8 ColorFormat = 0x0009200408 ColorFormat_NonColor16 ColorFormat = 0x0009200A10 ColorFormat_NonColor24 ColorFormat = 0x0009201A18 ColorFormat_NonColor32 ColorFormat = 0x0009201C20 ColorFormat_X4C4 ColorFormat = 0x0009210508 ColorFormat_A4L4 ColorFormat = 0x0100490508 ColorFormat_A8L8 ColorFormat = 0x0100490E10 ColorFormat_Float_A16L16 ColorFormat = 0x0100495D20 ColorFormat_A1B5G5R5 ColorFormat = 0x0100531410 ColorFormat_A4B4G4R4 ColorFormat = 0x0100531510 ColorFormat_A5B5G5R1 ColorFormat = 0x0100531810 ColorFormat_A2B10G10R10 ColorFormat = 0x0100532020 ColorFormat_A8B8G8R8 ColorFormat = 0x0100532120 ColorFormat_A16B16G16R16 ColorFormat = 0x0100532740 ColorFormat_Float_A16B16G16R16 ColorFormat = 0x0100536740 ColorFormat_A1R5G5B5 ColorFormat = 0x0100D11410 ColorFormat_A4R4G4B4 ColorFormat = 0x0100D11510 ColorFormat_A5R1G5B5 ColorFormat = 0x0100D11610 ColorFormat_A2R10G10B10 ColorFormat = 0x0100D12020 ColorFormat_A8R8G8B8 ColorFormat = 0x0100D12120 ColorFormat_A1 ColorFormat = 0x0101240101 ColorFormat_A2 ColorFormat = 0x0101240202 ColorFormat_A4 ColorFormat = 0x0101240304 ColorFormat_A8 ColorFormat = 0x0101240408 ColorFormat_A16 ColorFormat = 0x0101240A10 ColorFormat_A32 ColorFormat = 0x0101241C20 ColorFormat_Float_A16 ColorFormat = 0x0101244A10 ColorFormat_L4A4 ColorFormat = 0x0102000508 ColorFormat_L8A8 ColorFormat = 0x0102000E10 ColorFormat_B4G4R4A4 ColorFormat = 0x01060A1510 ColorFormat_B5G5R1A5 ColorFormat = 0x01060A1710 ColorFormat_B5G5R5A1 ColorFormat = 0x01060A1810 ColorFormat_B8G8R8A8 ColorFormat = 0x01060A2120 ColorFormat_B10G10R10A2 ColorFormat = 0x01060A2320 ColorFormat_R1G5B5A5 ColorFormat = 0x0106881410 ColorFormat_R4G4B4A4 ColorFormat = 0x0106881510 ColorFormat_R5G5B5A1 ColorFormat = 0x0106881810 ColorFormat_R8G8B8A8 ColorFormat = 0x0106882120 ColorFormat_R10G10B10A2 ColorFormat = 0x0106882320 ColorFormat_L1 ColorFormat = 0x010A000101 ColorFormat_L2 ColorFormat = 0x010A000202 ColorFormat_L4 ColorFormat = 0x010A000304 ColorFormat_L8 ColorFormat = 0x010A000408 ColorFormat_L16 ColorFormat = 0x010A000A10 ColorFormat_L32 ColorFormat = 0x010A001C20 ColorFormat_Float_L16 ColorFormat = 0x010A004A10 ColorFormat_B5G6R5 ColorFormat = 0x010A0A1210 ColorFormat_B6G5R5 ColorFormat = 0x010A0A1310 ColorFormat_B5G5R5X1 ColorFormat = 0x010A0A1810 ColorFormat_B8_G8_R8 ColorFormat = 0x010A0A1918 ColorFormat_B8G8R8X8 ColorFormat = 0x010A0A2120 ColorFormat_Float_B10G11R11 ColorFormat = 0x010A0A5E20 ColorFormat_X1B5G5R5 ColorFormat = 0x010A531410 ColorFormat_X8B8G8R8 ColorFormat = 0x010A532120 ColorFormat_X16B16G16R16 ColorFormat = 0x010A532740 ColorFormat_Float_X16B16G16R16 ColorFormat = 0x010A536740 ColorFormat_R3G3B2 ColorFormat = 0x010A880608 ColorFormat_R5G5B6 ColorFormat = 0x010A881110 ColorFormat_R5G6B5 ColorFormat = 0x010A881210 ColorFormat_R5G5B5X1 ColorFormat = 0x010A881810 ColorFormat_R8_G8_B8 ColorFormat = 0x010A881918 ColorFormat_R8G8B8X8 ColorFormat = 0x010A882120 ColorFormat_X1R5G5B5 ColorFormat = 0x010AD11410 ColorFormat_X8R8G8B8 ColorFormat = 0x010AD12120 ColorFormat_RG8 ColorFormat = 0x010B080E10 ColorFormat_R16G16 ColorFormat = 0x010B081D20 ColorFormat_Float_R16G16 ColorFormat = 0x010B085D20 ColorFormat_R8 ColorFormat = 0x010B200408 ColorFormat_R16 ColorFormat = 0x010B200A10 ColorFormat_Float_R16 ColorFormat = 0x010B204A10 ColorFormat_A2B10G10R10_sRGB ColorFormat = 0x0200532020 ColorFormat_A8B8G8R8_sRGB ColorFormat = 0x0200532120 ColorFormat_A16B16G16R16_sRGB ColorFormat = 0x0200532740 ColorFormat_A2R10G10B10_sRGB ColorFormat = 0x0200D12020 ColorFormat_B10G10R10A2_sRGB ColorFormat = 0x02060A2320 ColorFormat_R10G10B10A2_sRGB ColorFormat = 0x0206882320 ColorFormat_X8B8G8R8_sRGB ColorFormat = 0x020A532120 ColorFormat_X16B16G16R16_sRGB ColorFormat = 0x020A532740 ColorFormat_A2B10G10R10_709 ColorFormat = 0x0300532020 ColorFormat_A8B8G8R8_709 ColorFormat = 0x0300532120 ColorFormat_A16B16G16R16_709 ColorFormat = 0x0300532740 ColorFormat_A2R10G10B10_709 ColorFormat = 0x0300D12020 ColorFormat_B10G10R10A2_709 ColorFormat = 0x03060A2320 ColorFormat_R10G10B10A2_709 ColorFormat = 0x0306882320 ColorFormat_X8B8G8R8_709 ColorFormat = 0x030A532120 ColorFormat_X16B16G16R16_709 ColorFormat = 0x030A532740 ColorFormat_A2B10G10R10_709_Linear ColorFormat = 0x0400532020 ColorFormat_A8B8G8R8_709_Linear ColorFormat = 0x0400532120 ColorFormat_A16B16G16R16_709_Linear ColorFormat = 0x0400532740 ColorFormat_A2R10G10B10_709_Linear ColorFormat = 0x0400D12020 ColorFormat_B10G10R10A2_709_Linear ColorFormat = 0x04060A2320 ColorFormat_R10G10B10A2_709_Linear ColorFormat = 0x0406882320 ColorFormat_X8B8G8R8_709_Linear ColorFormat = 0x040A532120 ColorFormat_X16B16G16R16_709_Linear ColorFormat = 0x040A532740 ColorFormat_Float_A16B16G16R16_scRGB_Linear ColorFormat = 0x0500536740 ColorFormat_A2B10G10R10_2020 ColorFormat = 0x0600532020 ColorFormat_A8B8G8R8_2020 ColorFormat = 0x0600532120 ColorFormat_A16B16G16R16_2020 ColorFormat = 0x0600532740 ColorFormat_A2R10G10B10_2020 ColorFormat = 0x0600D12020 ColorFormat_B10G10R10A2_2020 ColorFormat = 0x06060A2320 ColorFormat_R10G10B10A2_2020 ColorFormat = 0x0606882320 ColorFormat_X8B8G8R8_2020 ColorFormat = 0x060A532120 ColorFormat_X16B16G16R16_2020 ColorFormat = 0x060A532740 ColorFormat_A2B10G10R10_2020_Linear ColorFormat = 0x0700532020 ColorFormat_A8B8G8R8_2020_Linear ColorFormat = 0x0700532120 ColorFormat_A16B16G16R16_2020_Linear ColorFormat = 0x0700532740 ColorFormat_Float_A16B16G16R16_2020_Linear ColorFormat = 0x0700536740 ColorFormat_A2R10G10B10_2020_Linear ColorFormat = 0x0700D12020 ColorFormat_B10G10R10A2_2020_Linear ColorFormat = 0x07060A2320 ColorFormat_R10G10B10A2_2020_Linear ColorFormat = 0x0706882320 ColorFormat_X8B8G8R8_2020_Linear ColorFormat = 0x070A532120 ColorFormat_X16B16G16R16_2020_Linear ColorFormat = 0x070A532740 ColorFormat_Float_A16B16G16R16_2020_PQ ColorFormat = 0x0800536740 ColorFormat_A4I4 ColorFormat = 0x0901210508 ColorFormat_A8I8 ColorFormat = 0x0901210E10 ColorFormat_I4A4 ColorFormat = 0x0903200508 ColorFormat_I8A8 ColorFormat = 0x0903200E10 ColorFormat_I1 ColorFormat = 0x0909200101 ColorFormat_I2 ColorFormat = 0x0909200202 ColorFormat_I4 ColorFormat = 0x0909200304 ColorFormat_I8 ColorFormat = 0x0909200408 ColorFormat_A8Y8U8V8 ColorFormat = 0x0A00D12120 ColorFormat_A16Y16U16V16 ColorFormat = 0x0A00D12740 ColorFormat_Y8U8V8A8 ColorFormat = 0x0A06882120 ColorFormat_V8_U8 ColorFormat = 0x0A080C0710 ColorFormat_V8U8 ColorFormat = 0x0A080C0E10 ColorFormat_V10U10 ColorFormat = 0x0A08142220 ColorFormat_V12U12 ColorFormat = 0x0A08142420 ColorFormat_V8 ColorFormat = 0x0A08240408 ColorFormat_V10 ColorFormat = 0x0A08240F10 ColorFormat_V12 ColorFormat = 0x0A08241010 ColorFormat_U8_V8 ColorFormat = 0x0A08440710 ColorFormat_U8V8 ColorFormat = 0x0A08440E10 ColorFormat_U10V10 ColorFormat = 0x0A08842220 ColorFormat_U12V12 ColorFormat = 0x0A08842420 ColorFormat_U8 ColorFormat = 0x0A09040408 ColorFormat_U10 ColorFormat = 0x0A09040F10 ColorFormat_U12 ColorFormat = 0x0A09041010 ColorFormat_Y8 ColorFormat = 0x0A09200408 ColorFormat_Y10 ColorFormat = 0x0A09200F10 ColorFormat_Y12 ColorFormat = 0x0A09201010 ColorFormat_YVYU ColorFormat = 0x0A0A500810 ColorFormat_VYUY ColorFormat = 0x0A0A500910 ColorFormat_YUYV ColorFormat = 0x0A0A880810 ColorFormat_UYVY ColorFormat = 0x0A0A880910 ColorFormat_Y8_U8_V8 ColorFormat = 0x0A0A881918 ColorFormat_V8_U8_RR ColorFormat = 0x0B080C0710 ColorFormat_V8U8_RR ColorFormat = 0x0B080C0E10 ColorFormat_V8_RR ColorFormat = 0x0B08240408 ColorFormat_U8_V8_RR ColorFormat = 0x0B08440710 ColorFormat_U8V8_RR ColorFormat = 0x0B08440E10 ColorFormat_U8_RR ColorFormat = 0x0B09040408 ColorFormat_Y8_RR ColorFormat = 0x0B09200408 ColorFormat_V8_U8_ER ColorFormat = 0x0C080C0710 ColorFormat_V8U8_ER ColorFormat = 0x0C080C0E10 ColorFormat_V8_ER ColorFormat = 0x0C08240408 ColorFormat_U8_V8_ER ColorFormat = 0x0C08440710 ColorFormat_U8V8_ER ColorFormat = 0x0C08440E10 ColorFormat_U8_ER ColorFormat = 0x0C09040408 ColorFormat_Y8_ER ColorFormat = 0x0C09200408 ColorFormat_V8_U8_709 ColorFormat = 0x0D080C0710 ColorFormat_V8U8_709 ColorFormat = 0x0D080C0E10 ColorFormat_V10U10_709 ColorFormat = 0x0D08142220 ColorFormat_V12U12_709 ColorFormat = 0x0D08142420 ColorFormat_V8_709 ColorFormat = 0x0D08240408 ColorFormat_V10_709 ColorFormat = 0x0D08240F10 ColorFormat_V12_709 ColorFormat = 0x0D08241010 ColorFormat_U8_V8_709 ColorFormat = 0x0D08440710 ColorFormat_U8V8_709 ColorFormat = 0x0D08440E10 ColorFormat_U10V10_709 ColorFormat = 0x0D08842220 ColorFormat_U12V12_709 ColorFormat = 0x0D08842420 ColorFormat_U8_709 ColorFormat = 0x0D09040408 ColorFormat_U10_709 ColorFormat = 0x0D09040F10 ColorFormat_U12_709 ColorFormat = 0x0D09041010 ColorFormat_Y8_709 ColorFormat = 0x0D09200408 ColorFormat_Y10_709 ColorFormat = 0x0D09200F10 ColorFormat_Y12_709 ColorFormat = 0x0D09201010 ColorFormat_V8_U8_709_ER ColorFormat = 0x0E080C0710 ColorFormat_V8U8_709_ER ColorFormat = 0x0E080C0E10 ColorFormat_V10U10_709_ER ColorFormat = 0x0E08142220 ColorFormat_V12U12_709_ER ColorFormat = 0x0E08142420 ColorFormat_V8_709_ER ColorFormat = 0x0E08240408 ColorFormat_V10_709_ER ColorFormat = 0x0E08240F10 ColorFormat_V12_709_ER ColorFormat = 0x0E08241010 ColorFormat_U8_V8_709_ER ColorFormat = 0x0E08440710 ColorFormat_U8V8_709_ER ColorFormat = 0x0E08440E10 ColorFormat_U10V10_709_ER ColorFormat = 0x0E08842220 ColorFormat_U12V12_709_ER ColorFormat = 0x0E08842420 ColorFormat_U8_709_ER ColorFormat = 0x0E09040408 ColorFormat_U10_709_ER ColorFormat = 0x0E09040F10 ColorFormat_U12_709_ER ColorFormat = 0x0E09041010 ColorFormat_Y8_709_ER ColorFormat = 0x0E09200408 ColorFormat_Y10_709_ER ColorFormat = 0x0E09200F10 ColorFormat_Y12_709_ER ColorFormat = 0x0E09201010 ColorFormat_V10U10_2020 ColorFormat = 0x0F08142220 ColorFormat_V12U12_2020 ColorFormat = 0x0F08142420 ColorFormat_V10_2020 ColorFormat = 0x0F08240F10 ColorFormat_V12_2020 ColorFormat = 0x0F08241010 ColorFormat_U10V10_2020 ColorFormat = 0x0F08842220 ColorFormat_U12V12_2020 ColorFormat = 0x0F08842420 ColorFormat_U10_2020 ColorFormat = 0x0F09040F10 ColorFormat_U12_2020 ColorFormat = 0x0F09041010 ColorFormat_Y10_2020 ColorFormat = 0x0F09200F10 ColorFormat_Y12_2020 ColorFormat = 0x0F09201010 ColorFormat_Bayer8RGGB ColorFormat = 0x1009200408 ColorFormat_Bayer16RGGB ColorFormat = 0x1009200A10 ColorFormat_BayerS16RGGB ColorFormat = 0x1009208A10 ColorFormat_X2Bayer14RGGB ColorFormat = 0x1009210B10 ColorFormat_X4Bayer12RGGB ColorFormat = 0x1009210C10 ColorFormat_X6Bayer10RGGB ColorFormat = 0x1009210D10 ColorFormat_Bayer8BGGR ColorFormat = 0x1109200408 ColorFormat_Bayer16BGGR ColorFormat = 0x1109200A10 ColorFormat_BayerS16BGGR ColorFormat = 0x1109208A10 ColorFormat_X2Bayer14BGGR ColorFormat = 0x1109210B10 ColorFormat_X4Bayer12BGGR ColorFormat = 0x1109210C10 ColorFormat_X6Bayer10BGGR ColorFormat = 0x1109210D10 ColorFormat_Bayer8GRBG ColorFormat = 0x1209200408 ColorFormat_Bayer16GRBG ColorFormat = 0x1209200A10 ColorFormat_BayerS16GRBG ColorFormat = 0x1209208A10 ColorFormat_X2Bayer14GRBG ColorFormat = 0x1209210B10 ColorFormat_X4Bayer12GRBG ColorFormat = 0x1209210C10 ColorFormat_X6Bayer10GRBG ColorFormat = 0x1209210D10 ColorFormat_Bayer8GBRG ColorFormat = 0x1309200408 ColorFormat_Bayer16GBRG ColorFormat = 0x1309200A10 ColorFormat_BayerS16GBRG ColorFormat = 0x1309208A10 ColorFormat_X2Bayer14GBRG ColorFormat = 0x1309210B10 ColorFormat_X4Bayer12GBRG ColorFormat = 0x1309210C10 ColorFormat_X6Bayer10GBRG ColorFormat = 0x1309210D10 ColorFormat_XYZ ColorFormat = 0x140A886640 ) var ColorFormatTable = []ColorFormat{ ColorFormat_A8B8G8R8, // PIXEL_FORMAT_RGBA_8888 ColorFormat_X8B8G8R8, // PIXEL_FORMAT_RGBX_8888 ColorFormat_R8_G8_B8, // PIXEL_FORMAT_RGB_888 <-- doesn't work ColorFormat_R5G6B5, // PIXEL_FORMAT_RGB_565 ColorFormat_A8R8G8B8, // PIXEL_FORMAT_BGRA_8888 ColorFormat_R5G5B5A1, // PIXEL_FORMAT_RGBA_5551 <-- doesn't work ColorFormat_A4B4G4R4, // PIXEL_FORMAT_RGBA_4444 }
bocke/abe-relive
Source/AliveLibAO/RollingBall.hpp
#pragma once #include "../AliveLibCommon/FunctionFwd.hpp" #include "Map.hpp" #include "BaseAliveGameObject.hpp" #include "../AliveLibAE/Path.hpp" namespace AO { struct Path_RollingBall final : public Path_TLV { Scale_short field_18_scale; XDirection_short field_1A_roll_direction; s16 field_1C_release_switch_id; u16 field_1E_speed; u16 field_20_acceleration; s16 field_22_pad; }; ALIVE_ASSERT_SIZEOF(Path_RollingBall, 0x24); class RollingBallShaker; class PathLine; class RollingBall final : public BaseAliveGameObject { public: EXPORT RollingBall* ctor_4578C0(Path_RollingBall* pTlv, s32 tlvInfo); EXPORT BaseGameObject* dtor_458230(); virtual BaseGameObject* VDestructor(s32 flags) override; EXPORT RollingBall* Vdtor_458490(s32 flags); virtual void VUpdate() override; EXPORT void VUpdate_457AF0(); EXPORT void Accelerate_458410(); EXPORT void CrushThingsInTheWay_458310(); s32 field_10C_tlvInfo; u16 field_110_release_switch_id; enum class States : s16 { eInactive_0, eStartRolling_1, eRolling_2, eFallingAndHittingWall_3, eCrushedBees_4 }; States field_112_state; RollingBallShaker* field_114_pRollingBallShaker; FP field_118_speed; FP field_11C_acceleration; PathLine* field_120_pCollisionLine; s32 field_124_padding; s32 field_128_padding; }; ALIVE_ASSERT_SIZEOF(RollingBall, 0x12C); } // namespace AO
Pokoi/TortillaEngine
Documentation/html/structglm_1_1detail_1_1make__signed_3_01unsigned_01short_01_4.js
<gh_stars>0 var structglm_1_1detail_1_1make__signed_3_01unsigned_01short_01_4 = [ [ "type", "structglm_1_1detail_1_1make__signed_3_01unsigned_01short_01_4.html#af5793ac48501a8fb2be1d5aa55afff67", null ] ];
jfallows/airline
airline-core/src/main/java/com/github/rvesse/airline/restrictions/factories/StringRestrictionFactory.java
/** * Copyright (C) 2010-16 the original author or authors. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package com.github.rvesse.airline.restrictions.factories; import java.lang.annotation.Annotation; import java.util.ArrayList; import java.util.List; import java.util.Locale; import com.github.rvesse.airline.annotations.restrictions.EndsWith; import com.github.rvesse.airline.annotations.restrictions.ExactLength; import com.github.rvesse.airline.annotations.restrictions.MaxLength; import com.github.rvesse.airline.annotations.restrictions.MinLength; import com.github.rvesse.airline.annotations.restrictions.NotBlank; import com.github.rvesse.airline.annotations.restrictions.NotEmpty; import com.github.rvesse.airline.annotations.restrictions.Pattern; import com.github.rvesse.airline.annotations.restrictions.StartsWith; import com.github.rvesse.airline.restrictions.AbstractCommonRestriction; import com.github.rvesse.airline.restrictions.ArgumentsRestriction; import com.github.rvesse.airline.restrictions.OptionRestriction; import com.github.rvesse.airline.restrictions.common.EndsWithRestriction; import com.github.rvesse.airline.restrictions.common.LengthRestriction; import com.github.rvesse.airline.restrictions.common.NotBlankRestriction; import com.github.rvesse.airline.restrictions.common.NotEmptyRestriction; import com.github.rvesse.airline.restrictions.common.PatternRestriction; import com.github.rvesse.airline.restrictions.common.StartsWithRestriction; public class StringRestrictionFactory implements ArgumentsRestrictionFactory, OptionRestrictionFactory { @Override public OptionRestriction createOptionRestriction(Annotation annotation) { return createCommon(annotation); } @Override public ArgumentsRestriction createArgumentsRestriction(Annotation annotation) { return createCommon(annotation); } protected AbstractCommonRestriction createCommon(Annotation annotation) { if (annotation instanceof Pattern) { Pattern pattern = (Pattern) annotation; return new PatternRestriction(pattern.pattern(), pattern.flags(), pattern.description()); } else if (annotation instanceof MaxLength) { MaxLength ml = (MaxLength) annotation; return new LengthRestriction(ml.length(), true); } else if (annotation instanceof MinLength) { MinLength ml = (MinLength) annotation; return new LengthRestriction(ml.length(), false); } else if (annotation instanceof ExactLength) { ExactLength el = (ExactLength) annotation; return new LengthRestriction(el.length(), el.length()); } else if (annotation instanceof NotBlank) { return new NotBlankRestriction(); } else if (annotation instanceof NotEmpty) { return new NotEmptyRestriction(); } else if (annotation instanceof EndsWith) { EndsWith ew = (EndsWith) annotation; return new EndsWithRestriction(ew.ignoreCase(), Locale.forLanguageTag(ew.locale()), ew.suffixes()); } else if (annotation instanceof StartsWith) { StartsWith sw = (StartsWith) annotation; return new StartsWithRestriction(sw.ignoreCase(), Locale.forLanguageTag(sw.locale()), sw.prefixes()); } return null; } protected List<Class<? extends Annotation>> supportedAnnotations() { List<Class<? extends Annotation>> supported = new ArrayList<>(); supported.add(Pattern.class); supported.add(MaxLength.class); supported.add(MinLength.class); supported.add(ExactLength.class); supported.add(NotBlank.class); supported.add(NotEmpty.class); supported.add(EndsWith.class); supported.add(StartsWith.class); return supported; } @Override public List<Class<? extends Annotation>> supportedOptionAnnotations() { return supportedAnnotations(); } @Override public List<Class<? extends Annotation>> supportedArgumentsAnnotations() { return supportedAnnotations(); } }
BroiSatse/dbview_cti
lib/db_view_cti/model/cti/association_validations.rb
<filename>lib/db_view_cti/model/cti/association_validations.rb module DBViewCTI module Model module CTI module AssociationValidations extend ActiveSupport::Concern included do # validations validate :cti_validate_associations, :cti_no_disable => true attr_accessor :cti_disable_validations end def cti_validate_associations return_value = true self.class.cti_association_proxies.each_key do |proxy_name| proxy = instance_variable_get(proxy_name) if proxy && !proxy.valid? errors.messages.merge!(proxy.errors.messages) return_value = false end end return_value end module ClassMethods # redefine validate to always add :unless proc so we can disable the validations for an object # by setting the cti_disable_validations accessor to true def validate(*args, &block) # we specifically don't want to disable balidations belonging to associations. Based on the naming # rails uses, we return immediately in such cases (there must be a cleaner way to do this...) return super if args.first && args.first.to_s =~ /^validate_associated_records_for_/ # rest of implementation insipred by the validate implementation in rails options = args.extract_options!.dup return super if options[:cti_no_disable] if options.key?(:unless) options[:unless] = Array(options[:unless]) options[:unless].unshift( cti_validation_unless_proc ) else options[:unless] = cti_validation_unless_proc end args << options return super(*args, &block) end def cti_validation_unless_proc @cti_validation_unless_proc ||= Proc.new do |object| object.respond_to?(:cti_disable_validations) && object.cti_disable_validations end end end end end end end
megahertz0/android_thunder
dex_src/com/xunlei/downloadprovider/ad/recommend/a/o.java
<reponame>megahertz0/android_thunder package com.xunlei.downloadprovider.ad.recommend.a; import android.database.Observable; import com.xunlei.downloadprovider.ad.common.c.a; import java.util.Arrays; import java.util.Iterator; import java.util.List; import java.util.Map; // compiled from: RecommendAdObservable.java public class o extends Observable<Map<Integer, a>> { private static final String a; static { a = o.class.getSimpleName(); } public final void a(int i, List<com.xunlei.downloadprovider.ad.common.a> list) { new StringBuilder("onloadSuccess: ").append(Arrays.toString(list.toArray())); Iterator it = this.mObservers.iterator(); while (it.hasNext()) { Map map = (Map) it.next(); if (map.containsKey(Integer.valueOf(i))) { ((a) map.get(Integer.valueOf(i))).a(list); } } } public final void a(int i, int i2, String str) { Iterator it = this.mObservers.iterator(); while (it.hasNext()) { Map map = (Map) it.next(); if (map.containsKey(Integer.valueOf(i))) { ((a) map.get(Integer.valueOf(i))).a(i2, str); } } } }
ckamtsikis/cmssw
SimRomanPot/SimFP420/src/ZeroSuppressFP420.cc
<filename>SimRomanPot/SimFP420/src/ZeroSuppressFP420.cc /////////////////////////////////////////////////////////////////////////////// // File: ZeroSuppressFP420.cc // Date: 12.2006 // Description: ZeroSuppressFP420 for FP420 // Modifications: /////////////////////////////////////////////////////////////////////////////// #include "FWCore/MessageLogger/interface/MessageLogger.h" #include "SimRomanPot/SimFP420/interface/ZeroSuppressFP420.h" ZeroSuppressFP420::ZeroSuppressFP420(const edm::ParameterSet &conf, float noise) : conf_(conf), theNumFEDalgos(4) { noiseInAdc = noise; initParams(conf_); verbosity = conf_.getUntrackedParameter<int>("VerbosityLevel"); // initParams(); if (verbosity > 0) { std::cout << "ZeroSuppressFP420: constructor: noiseInAdc= " << noiseInAdc << std::endl; } } /* * The zero suppression algorithm, implemented in the trkFEDclusterizer method. * The class publically inherits from the ZSuppressFP420 class, which requires * the use of a method named zeroSuppress. */ void ZeroSuppressFP420::initParams(edm::ParameterSet const &conf_) { verbosity = conf_.getUntrackedParameter<int>("VerbosityLevel"); algoConf = conf_.getParameter<int>("FedFP420Algorithm"); // FedFP420Algorithm: =1 (,2,3,4) lowthreshConf = conf_.getParameter<double>("FedFP420LowThreshold"); // FedFP420LowThreshold =3. highthreshConf = conf_.getParameter<double>("FedFP420HighThreshold"); // FedFP420HighThreshold =4. /* * There are four possible algorithms, the default of which (4) * has different thresholds for isolated channels and ones in clusters. * It also merges clusters (single or multi channels) that are only separated * by one hole. This channel is selected as signal even though it is below * both thresholds. */ theFEDalgorithm = algoConf; theFEDlowThresh = lowthreshConf * noiseInAdc; theFEDhighThresh = highthreshConf * noiseInAdc; if (verbosity > 0) { std::cout << "ZeroSuppressFP420: initParams: !!! theFEDalgorithm= " << theFEDalgorithm << std::endl; std::cout << " lowthreshConf= " << lowthreshConf << " highthreshConf= " << highthreshConf << " theFEDlowThresh= " << theFEDlowThresh << " theFEDhighThresh= " << theFEDhighThresh << std::endl; } // Check zero suppress algorithm if (theFEDalgorithm < 1 || theFEDalgorithm > theNumFEDalgos) { edm::LogError("FP420DigiInfo") << "ZeroSuppressFP420 FATAL ERROR: Unknown zero suppress algorithm " << theFEDalgorithm; exit(1); } // Check thresholds if (theFEDlowThresh > theFEDhighThresh) { edm::LogError("FP420DigiInfo") << "ZeroSuppressFP420 FATAL ERROR: Low threshold exceeds high " "threshold: " << theFEDlowThresh << " > " << theFEDhighThresh; exit(2); } } ZSuppressFP420::DigitalMapType ZeroSuppressFP420::zeroSuppress(const DigitalMapType &notZeroSuppressedMap, int vrb) { return trkFEDclusterizer(notZeroSuppressedMap, vrb); if (vrb > 0) { std::cout << "zeroSuppress: return trkFEDclusterizer(notZeroSuppressedMap)" << std::endl; } } // This performs the zero suppression ZSuppressFP420::DigitalMapType ZeroSuppressFP420::trkFEDclusterizer(const DigitalMapType &in, int vrb) { const std::string s2("ZeroSuppressFP420::trkFEDclusterizer1"); DigitalMapType selectedSignal; DigitalMapType::const_iterator i, iPrev, iNext, iPrev2, iNext2; if (vrb > 0) { std::cout << "Before For loop" << std::endl; } for (i = in.begin(); i != in.end(); i++) { // Find adc values for neighbouring strips int strip = i->first; int adc = i->second; iPrev = in.find(strip - 1); iNext = in.find(strip + 1); if (vrb > 0) { std::cout << "Inside For loop trkFEDclusterizer: strip= " << strip << " adc= " << adc << std::endl; } // Set values for channels just outside module to infinity. // This is to avoid losing channels at the edges, // which otherwise would pass cuts if strips were next to each other. int adcPrev = -99999; int adcNext = -99999; if (((strip) % 128) == 127) adcNext = 99999; if (((strip) % 128) == 0) adcPrev = 99999; // Otherwise if channel was found then find it's ADC count. if (iPrev != in.end()) adcPrev = iPrev->second; if (iNext != in.end()) adcNext = iNext->second; int adcMaxNeigh = std::max(adcPrev, adcNext); if (vrb > 0) { std::cout << "adcPrev= " << adcPrev << " adcNext= " << adcNext << " adcMaxNeigh= " << adcMaxNeigh << std::endl; } // Find adc values for next neighbouring channes iPrev2 = in.find(strip - 2); iNext2 = in.find(strip + 2); // See above int adcPrev2 = -99999; int adcNext2 = -99999; if (((strip) % 128) == 126) adcNext2 = 99999; if (((strip) % 128) == 1) adcPrev2 = 99999; if (iPrev2 != in.end()) adcPrev2 = iPrev2->second; if (iNext2 != in.end()) adcNext2 = iNext2->second; if (vrb > 0) { std::cout << "adcPrev2= " << adcPrev2 << " adcNext2= " << adcNext2 << std::endl; std::cout << "To be accepted or not? adc= " << adc << " >= theFEDlowThresh=" << theFEDlowThresh << std::endl; } // Decide if this channel should be accepted. bool accept = false; switch (theFEDalgorithm) { case 1: accept = (adc >= theFEDlowThresh); break; case 2: accept = (adc >= theFEDhighThresh || (adc >= theFEDlowThresh && adcMaxNeigh >= theFEDlowThresh)); break; case 3: accept = (adc >= theFEDhighThresh || (adc >= theFEDlowThresh && adcMaxNeigh >= theFEDhighThresh)); break; case 4: accept = ((adc >= theFEDhighThresh) || // Test for adc>highThresh (same as // algorithm 2) ((adc >= theFEDlowThresh) && // Test for adc>lowThresh, with neighbour // adc>lowThresh (same as algorithm 2) (adcMaxNeigh >= theFEDlowThresh)) || ((adc < theFEDlowThresh) && // Test for adc<lowThresh (((adcPrev >= theFEDhighThresh) && // with both neighbours>highThresh (adcNext >= theFEDhighThresh)) || ((adcPrev >= theFEDhighThresh) && // OR with previous neighbour>highThresh and (adcNext >= theFEDlowThresh) && // both the next neighbours>lowThresh (adcNext2 >= theFEDlowThresh)) || ((adcNext >= theFEDhighThresh) && // OR with next neighbour>highThresh and (adcPrev >= theFEDlowThresh) && // both the previous neighbours>lowThresh (adcPrev2 >= theFEDlowThresh)) || ((adcNext >= theFEDlowThresh) && // OR with both next neighbours>lowThresh and (adcNext2 >= theFEDlowThresh) && // both the previous neighbours>lowThresh (adcPrev >= theFEDlowThresh) && (adcPrev2 >= theFEDlowThresh))))); break; } /* * When a channel satisfying only the lower threshold is at the edge of an * APV or module, the trkFEDclusterizer method assumes that every channel * just outside an APV or module has a hit on it. This is to avoid channel * inefficiencies at the edges of APVs and modules. */ if (accept) { selectedSignal[strip] = adc; if (vrb > 0) { std::cout << "selected strips = " << strip << " adc= " << adc << std::endl; } } } if (vrb > 0) { std::cout << "last line of trkFEDclusterizer: return selectedSignal" << std::endl; } return selectedSignal; }
jfehren/Crypto
hash/sha2/sha512-internal.h
/* * sha512-internal.h * * Created on: Apr 27, 2019, 6:13:50 PM * Author: <NAME> */ #ifndef SHA2_SHA512_INTERNAL_H_ #define SHA2_SHA512_INTERNAL_H_ #include "sha2.h" #ifdef __cplusplus extern "C" { #endif #if __IS_x86__ && CRYPTO_FAT #define _sha512_compress (*_crypto_sha512_compress_fat) #define _sha512_compress_gen _crypto_sha512_compress_gen #define _sha512_compress_x64 _crypto_sha512_compress_x64 void _sha512_compress_x64(uint64_t *state, const uint8_t *data, size_t length, const uint64_t *K); extern void _sha512_compress(uint64_t *state, const uint8_t *data, size_t length, const uint64_t *K); #else #define _sha512_compress _crypto_sha512_compress #define _sha512_compress_gen _sha512_compress #endif void _sha512_compress_gen(uint64_t *state, const uint8_t *data, size_t length, const uint64_t *K); #ifdef __cplusplus } #endif #endif /* SHA2_SHA512_INTERNAL_H_ */
fncolon/Belajar-Dengan-Jenius-AWS-Node.js
Chapter3-Mastering-Javascript/S5.Function/23.clean-code-2.js
<reponame>fncolon/Belajar-Dengan-Jenius-AWS-Node.js // bad if (currentUser) { function test() { console.log('Nope.'); } } // good let test; if (currentUser) { test = () => { console.log('Yup.'); }; } // Note: ECMA - 262 defines a block as a list of statements.A function declaration is not a statement.
venkatramanm/common
src/test/java/com/venky/core/util/PackageUtilTest.java
/* * To change this template, choose Tools | Templates * and open the template in the editor. */ package com.venky.core.util; import java.io.IOException; import java.net.URL; import org.junit.After; import org.junit.AfterClass; import org.junit.Before; import org.junit.BeforeClass; import org.junit.Test; /** * * @author venky */ public class PackageUtilTest { public PackageUtilTest() { } @BeforeClass public static void setUpClass() throws Exception { } @AfterClass public static void tearDownClass() throws Exception { } @Before public void setUp() { } @After public void tearDown() { } @Test public void testJar() throws IOException { URL url = getClass().getClassLoader().getResource("java/lang/String.class"); for (String s : PackageUtil.getClasses(url,"java/lang/String")){ System.out.println(s); } } @Test public void testDirectory() throws IOException{ URL url = new URL("file:/home/venky/Projects/java/oss/core/target/classes"); for (String s : PackageUtil.getClasses(url,"com/venky/core/date")){ System.out.println(s); } } }
crowmurk/mallenom
mallenom/api/urls.py
<filename>mallenom/api/urls.py from django.urls import path, include from . import views app_name = 'api' employment = [ path('', views.EmploymentListEmployee.as_view(), name='list'), ] employee = [ path('<int:pk>/employment/', include((employment, 'employment'))), ] urlpatterns = [ path('employee/', include((employee, 'employee'))), ]
MantledIllusion/epiphy
src/test/java/com/mantledillusion/data/epiphy/set/test/DropSetModelPropertyTest.java
package com.mantledillusion.data.epiphy.set.test; import com.mantledillusion.data.epiphy.exception.InterruptedPropertyPathException; import com.mantledillusion.data.epiphy.exception.UnknownDropableElementException; import com.mantledillusion.data.epiphy.set.AbstractSetModelPropertyTest; import com.mantledillusion.data.epiphy.set.SetModelProperties; import org.junit.jupiter.api.Test; import static org.junit.jupiter.api.Assertions.*; public class DropSetModelPropertyTest extends AbstractSetModelPropertyTest { @Test public void testDrop() { assertEquals(ELEMENT_A, SetModelProperties.ELEMENTSET.drop(this.model, ELEMENT_A)); assertEquals(1, this.model.getObjects().size()); assertSame(ELEMENT_B, this.model.getObjects().iterator().next()); } @Test public void testDropUnknown() { assertThrows(UnknownDropableElementException.class, () -> { SetModelProperties.ELEMENTSET.drop(this.model, NEW_ELEMENT); }); } @Test public void testDropInterrupted() { this.model.setObjects(null); assertThrows(InterruptedPropertyPathException.class, () -> { SetModelProperties.ELEMENTSET.drop(this.model, ELEMENT_A); }); } }
Haehnchen/idea-php-shopware-plugin
src/main/java/de/espend/idea/shopware/completion/ShopwareXmlCompletion.java
package de.espend.idea.shopware.completion; import com.intellij.codeInsight.completion.*; import com.intellij.codeInsight.lookup.LookupElementBuilder; import com.intellij.patterns.PlatformPatterns; import com.intellij.psi.PsiElement; import com.intellij.psi.xml.XmlTag; import com.intellij.util.ProcessingContext; import de.espend.idea.shopware.ShopwareProjectComponent; import de.espend.idea.shopware.util.ShopwareUtil; import de.espend.idea.shopware.util.XmlPatternUtil; import org.apache.commons.lang.StringUtils; import org.jetbrains.annotations.NotNull; import org.jetbrains.annotations.Nullable; /** * @author <NAME> <<EMAIL>> */ public class ShopwareXmlCompletion extends CompletionContributor { public ShopwareXmlCompletion() { extend(CompletionType.BASIC, PlatformPatterns.or(XmlPatternUtil.getMenuControllerPattern(), XmlPatternUtil.getMenuControllerByParentPattern()), new MenuControllerProvider()); extend(CompletionType.BASIC, XmlPatternUtil.getMenuControllerActionPattern(), new MenuControllerActionProvider()); } private class MenuControllerProvider extends CompletionProvider<CompletionParameters> { @Override protected void addCompletions(@NotNull CompletionParameters completionParameters, ProcessingContext processingContext, @NotNull CompletionResultSet completionResultSet) { ShopwareUtil.collectControllerClass(completionParameters.getPosition().getProject(), (phpClass, moduleName, controllerName) -> { LookupElementBuilder lookupElement = LookupElementBuilder.create(controllerName) .withIcon(phpClass.getIcon()) .withTypeText(phpClass.getPresentableFQN(), true); completionResultSet.addElement(lookupElement); }, "Backend"); } } private class MenuControllerActionProvider extends CompletionProvider<CompletionParameters> { @Override protected void addCompletions(@NotNull CompletionParameters completionParameters, ProcessingContext processingContext, @NotNull CompletionResultSet completionResultSet) { PsiElement psiElement = completionParameters.getOriginalPosition(); if(psiElement == null || !ShopwareProjectComponent.isValidForProject(psiElement)) { return; } PsiElement parent = psiElement.getParent(); if(!(parent instanceof XmlTag)) { return; } String controllerName = getControllerOnScope((XmlTag) parent); if (controllerName == null) { return; } ShopwareUtil.collectControllerAction(psiElement.getProject(), controllerName, (method, methodStripped, moduleName, controllerName1) -> { LookupElementBuilder lookupElement = LookupElementBuilder.create(methodStripped) .withIcon(method.getIcon()) .withTypeText(method.getName(), true); completionResultSet.addElement(lookupElement); }, "Backend"); } } @Nullable public static String getControllerOnScope(@NotNull XmlTag xmlTag) { PsiElement menuTag = xmlTag.getParent(); if(!(menuTag instanceof XmlTag)) { return null; } String name = ((XmlTag) menuTag).getName(); if(!"entry".equals(name)) { return null; } XmlTag controller = ((XmlTag) menuTag).findFirstSubTag("controller"); if(controller == null) { return null; } String controllerName = controller.getValue().getTrimmedText(); if(StringUtils.isBlank(controllerName)) { return null; } return controllerName; } }
m-m-m/util
nls/src/main/java/net/sf/mmm/util/nls/api/NlsObject.java
<gh_stars>1-10 /* Copyright (c) The m-m-m Team, Licensed under the Apache License, Version 2.0 * http://www.apache.org/licenses/LICENSE-2.0 */ package net.sf.mmm.util.nls.api; /** * This is the interface for an object with native language support. Such object be can {@link #toNlsMessage() * converted} to an {@link NlsMessage i18n-message} describing the object analog to its {@link Object#toString() string * representation}. * * @author <NAME> (hohwille at users.sourceforge.net) * @since 1.0.0 */ public interface NlsObject { /** Key for the {@link NlsMessage#getArgument(String) argument} {@value}. */ String KEY_OBJECT = "object"; /** Key for the {@link NlsMessage#getArgument(String) argument} {@value}. */ String KEY_KEY = "key"; /** Key for the {@link NlsMessage#getArgument(String) argument} {@value}. */ String KEY_ID = "id"; /** Key for the {@link NlsMessage#getArgument(String) argument} {@value}. */ String KEY_VALUE = "value"; /** Key for the {@link NlsMessage#getArgument(String) argument} {@value}. */ String KEY_TYPE = "type"; /** Key for the {@link NlsMessage#getArgument(String) argument} {@value}. */ String KEY_SOURCE = "source"; /** Key for the {@link NlsMessage#getArgument(String) argument} {@value}. */ String KEY_MIN = "min"; /** Key for the {@link NlsMessage#getArgument(String) argument} {@value}. */ String KEY_MAX = "max"; /** Key for the {@link NlsMessage#getArgument(String) argument} {@value}. */ String KEY_RESOURCE = "resource"; /** Key for the {@link NlsMessage#getArgument(String) argument} {@value}. */ String KEY_SIZE = "size"; /** Key for the {@link NlsMessage#getArgument(String) argument} {@value}. */ String KEY_CAPACITY = "capacity"; /** Key for the {@link NlsMessage#getArgument(String) argument} {@value}. */ String KEY_PROPERTY = "property"; /** Key for the {@link NlsMessage#getArgument(String) argument} {@value}. */ String KEY_PATH = "path"; /** Key for the {@link NlsMessage#getArgument(String) argument} {@value}. */ String KEY_NAME = "name"; /** Key for the {@link NlsMessage#getArgument(String) argument} {@value}. */ String KEY_OPTION = "option"; /** Key for the {@link NlsMessage#getArgument(String) argument} {@value}. */ String KEY_MODE = "mode"; /** Key for the {@link NlsMessage#getArgument(String) argument} {@value}. */ String KEY_FILE = "file"; /** Key for the {@link NlsMessage#getArgument(String) argument} {@value}. */ String KEY_DIRECTORY = "directory"; /** Key for the {@link NlsMessage#getArgument(String) argument} {@value}. */ String KEY_OPERAND = "operand"; /** Key for the {@link NlsMessage#getArgument(String) argument} {@value}. */ String KEY_DEFAULT = "default"; /** Key for the {@link NlsMessage#getArgument(String) argument} {@value}. */ String KEY_ARGUMENT = "argument"; /** Key for the {@link NlsMessage#getArgument(String) argument} {@value}. */ String KEY_FUNCTION = "function"; /** Key for the {@link NlsMessage#getArgument(String) argument} {@value}. */ String KEY_OPERATION = "operation"; /** Key for the {@link NlsMessage#getArgument(String) argument} {@value}. */ String KEY_TARGET_TYPE = "targetType"; /** Key for the {@link NlsMessage#getArgument(String) argument} {@value}. */ String KEY_ANNOTATION = "annotation"; /** Key for the {@link NlsMessage#getArgument(String) argument} {@value}. */ String KEY_LOCATION = "location"; /** Key for the {@link NlsMessage#getArgument(String) argument} {@value}. */ String KEY_QUERY = "query"; /** Key for the {@link NlsMessage#getArgument(String) argument} {@value}. */ String KEY_URI = "uri"; /** Key for the {@link NlsMessage#getArgument(String) argument} {@value}. */ String KEY_TITLE = "title"; /** * Key for the {@link NlsMessage#getArgument(String) argument} {@value}. * * @since 2.0.1 */ String KEY_ERROR = "error"; /** * Key for the {@link NlsMessage#getArgument(String) argument} {@value}. * * @since 3.0.0 */ String KEY_USER = "user"; /** * Key for the {@link NlsMessage#getArgument(String) argument} {@value}. * * @since 3.0.0 */ String KEY_EXISTING = "existing"; /** * Key for the {@link NlsMessage#getArgument(String) argument} {@value}. * * @since 3.0.0 */ String KEY_EXPECTED = "expected"; /** * Key for the {@link NlsMessage#getArgument(String) argument} {@value}. * * @since 3.0.0 */ String KEY_CONTAINER = "container"; /** * This method is the equivalent to {@link Object#toString()} with native language support. * * @return an nls message representing this object. */ NlsMessage toNlsMessage(); }
VTracyHuang/yx-framework
yx-generator/src/main/java/com/yx/code/service/ISysEmailLogService.java
package com.yx.code.service; import com.yx.code.entity.SysEmailLog; import com.yx.common.core.base.BaseService; /** * <p> * 服务类 * </p> * * @author TangHuaLiang * @since 2019-02-28 */ public interface ISysEmailLogService extends BaseService<SysEmailLog> { }
dterletskiy/carpc
framework/imp/sys/command/Types.cpp
<gh_stars>1-10 #include "api/sys/command/Types.hpp" namespace carpc::command { }
prise-3d/macop
macop/evaluators/discrete/multi.py
<reponame>prise-3d/macop """Multi-objective evaluators classes for discrete problem """ # main imports from macop.evaluators.base import Evaluator class WeightedSum(Evaluator): """Weighted-sum sub-evaluator class which enables to compute solution using specific `_data` - stores into its `_data` dictionary attritute required measures when computing a solution - `_data['evaluators']` current evaluator to use - `_data['weights']` Associated weight to use - `compute` method enables to compute and associate a tuples of scores to a given solution >>> import random >>> >>> # binary solution import >>> from macop.solutions.discrete import BinarySolution >>> >>> # evaluators imports >>> from macop.evaluators.discrete.mono import KnapsackEvaluator >>> from macop.evaluators.discrete.multi import WeightedSum >>> solution_data = [1, 0, 0, 1, 1, 0, 1, 0] >>> size = len(solution_data) >>> solution = BinarySolution(solution_data, size) >>> >>> # evaluator 1 initialization (worths objects passed into data) >>> worths1 = [ random.randint(5, 20) for i in range(size) ] >>> evaluator1 = KnapsackEvaluator(data={'worths': worths1}) >>> >>> # evaluator 2 initialization (worths objects passed into data) >>> worths2 = [ random.randint(10, 15) for i in range(size) ] >>> evaluator2 = KnapsackEvaluator(data={'worths': worths2}) >>> weighted_evaluator = WeightedSum(data={'evaluators': [evaluator1, evaluator2], 'weights': [0.3, 0.7]}) >>> >>> # compute score and check with expected one >>> weighted_score = weighted_evaluator.compute(solution) >>> expected_score = evaluator1.compute(solution) * 0.3 + evaluator2.compute(solution) * 0.7 >>> weighted_score == expected_score True >>> weighted_score 50.8 """ def compute(self, solution): """Apply the computation of fitness from solution - Associate tuple of fitness scores for each objective to the current solution - Compute weighted-sum for these objectives Args: solution: {:class:`~macop.solutions.base.Solution`} -- Solution instance Returns: {float}: weighted-sum of the fitness scores """ scores = [ evaluator.compute(solution) for evaluator in self._data['evaluators'] ] # associate objectives scores to solution solution.scores = scores return sum( [scores[i] * w for i, w in enumerate(self._data['weights'])])
enhance-dev/enhance-styles
weights.js
module.exports = function (query='') { return /*css*/` /* WEIGHTS */ .font-hairline${query}{font-weight:100;} .font-thin${query}{font-weight:200;} .font-light${query}{font-weight:300;} .font-normal${query}{font-weight:400;} .font-medium${query}{font-weight:500;} .font-semibold${query}{font-weight:600;} .font-bold${query}{font-weight:700;} .font-extrabold${query}{font-weight:800;} .font-black${query}{font-weight:900;} ` }
jmartisk/syndesis-qe
rest-tests/src/test/java/io/syndesis/qe/rest/tests/integrations/KafkaSteps.java
package io.syndesis.qe.rest.tests.integrations; import org.springframework.beans.factory.annotation.Autowired; import java.util.Map; import java.util.UUID; import cucumber.api.java.en.Given; import cucumber.api.java.en.When; import io.syndesis.common.model.DataShapeKinds; import io.syndesis.common.model.action.Action; import io.syndesis.common.model.action.ConnectorDescriptor; import io.syndesis.common.model.connection.Connection; import io.syndesis.common.model.connection.Connector; import io.syndesis.common.model.integration.Step; import io.syndesis.common.model.integration.StepKind; import io.syndesis.qe.bdd.AbstractStep; import io.syndesis.qe.bdd.entities.StepDefinition; import io.syndesis.qe.bdd.storage.StepsStorage; import io.syndesis.qe.endpoints.ConnectionsEndpoint; import io.syndesis.qe.endpoints.ConnectorsEndpoint; import io.syndesis.qe.utils.RestConstants; import io.syndesis.qe.utils.TestUtils; public class KafkaSteps extends AbstractStep { @Autowired private StepsStorage steps; @Autowired private ConnectionsEndpoint connectionsEndpoint; @Autowired private ConnectorsEndpoint connectorsEndpoint; private Connector kafkaConnector; private Connection kafkaConnection; private Action kafkaAction; private Map<String, String> properties; private void init(String action, String topic) { kafkaConnector = connectorsEndpoint.get("kafka"); kafkaConnection = connectionsEndpoint.get(RestConstants.KAFKA_CONNECTION_ID); kafkaAction = TestUtils.findConnectorAction(kafkaConnector, action); properties = TestUtils.map( "topic", topic ); } @When("^create Kafka publish step with datashape and with topic \"([^\"]*)\"$") public void createKafkaPublishStepWithDatashape(String topic) { init("kafka-publish-action", topic); final ConnectorDescriptor connectorDescriptor = getConnectorDescriptor(kafkaAction, properties, RestConstants.KAFKA_CONNECTION_ID); final Step kafkaStep = new Step.Builder() .stepKind(StepKind.endpoint) .id(UUID.randomUUID().toString()) .connection(kafkaConnection) .action(withCustomDatashape(kafkaAction, connectorDescriptor, "in", DataShapeKinds.JSON_SCHEMA, "{\"$schema\":\"http://json" + "-schema.org/draft-04/schema#\",\"type\":\"object\",\"properties\":{\"Id\":{\"type\":\"string\"}},\"required\":[\"Id\"]}")) .configuredProperties(properties) .build(); steps.getStepDefinitions().add(new StepDefinition(kafkaStep)); } @Given("^create Kafka subscribe step with topic \"([^\"]*)\"$") public void createKafkaSubscribeStepWithTopic(String topic) { init("kafka-subscribe-action", topic); final Step kafkaStep = new Step.Builder() .stepKind(StepKind.endpoint) .id(UUID.randomUUID().toString()) .connection(kafkaConnection) .action(kafkaAction) .configuredProperties(properties) .build(); steps.getStepDefinitions().add(new StepDefinition(kafkaStep)); } }
frag997/p5-plus-plus
Book-TheNatureOfCode/chapter_06_autonomous_agent/Steering: Seek/vehicle.js
<reponame>frag997/p5-plus-plus function Vehicle(x, y, n){ this.pos = createVector(x, y); this.vel = createVector(0, 0); this.acc = createVector(0, 0); this.maxspeed = 7; this.maxforce = 0.3; this.seek = function(target){ let desired = p5.Vector.sub(target, this.pos); desired.setMag(this.maxspeed); let steering = p5.Vector.sub(desired, this.vel); steering.limit(this.maxforce); this.applyForce(steering); } this.applyForce = function(force){ this.acc.add(force); } this.update = function(){ this.vel.add(this.acc); this.vel.limit(this.maxspeed); this.pos.add(this.vel); this.acc.set(0.0); } this.display = function(){ fill(255, 99, 77); strokeWeight(3); stroke(255); ellipse(this.pos.x, this.pos.y, 63, 63); } }
jonathanxqs/lintcode
124.cpp
class Solution { public: /** * @param nums: A list of integers * @return an integer */ int longestConsecutive(vector<int>& nums) { unordered_map<int, bool> hash; for (int i = 0; i < nums.size(); i++) { hash[nums[i]] = true; } int max = 0; for (int i = 0; i < nums.size(); i++) { int up = nums[i]; while (hash.find(up) != hash.end()) { hash.erase(up); up++; } int down = nums[i] - 1; while (hash.find(down) != hash.end()) { hash.erase(down); down--; } if (up - down - 1 > max) { max = up - down - 1; } } return max; } }; // Total Runtime: 32 ms
jhh67/chapel
third-party/jemalloc/jemalloc-src/scripts/gen_travis.py
<gh_stars>1000+ #!/usr/bin/env python from itertools import combinations travis_template = """\ language: generic matrix: include: %s before_script: - autoconf - ./configure ${COMPILER_FLAGS:+ \ CC="$CC $COMPILER_FLAGS" } \ $CONFIGURE_FLAGS - make -j3 - make -j3 tests script: - make check """ # The 'default' configuration is gcc, on linux, with no compiler or configure # flags. We also test with clang, -m32, --enable-debug, --enable-prof, # --disable-stats, and --disable-tcache. To avoid abusing travis though, we # don't test all 2**7 = 128 possible combinations of these; instead, we only # test combinations of up to 2 'unusual' settings, under the hope that bugs # involving interactions of such settings are rare. # things at once, for C(7, 0) + C(7, 1) + C(7, 2) = 29 MAX_UNUSUAL_OPTIONS = 2 os_default = 'linux' os_unusual = 'osx' compilers_default = 'CC=gcc' compilers_unusual = 'CC=clang' compiler_flag_unusuals = ['-m32'] configure_flag_unusuals = [ '--enable-debug', '--enable-prof', '--disable-stats', '--disable-tcache', ] all_unusuals = ( [os_unusual] + [compilers_unusual] + compiler_flag_unusuals + configure_flag_unusuals ) unusual_combinations_to_test = [] for i in xrange(MAX_UNUSUAL_OPTIONS + 1): unusual_combinations_to_test += combinations(all_unusuals, i) include_rows = "" for unusual_combination in unusual_combinations_to_test: os = os_default if os_unusual in unusual_combination: os = os_unusual compilers = compilers_default if compilers_unusual in unusual_combination: compilers = compilers_unusual compiler_flags = [ x for x in unusual_combination if x in compiler_flag_unusuals] configure_flags = [ x for x in unusual_combination if x in configure_flag_unusuals] # Filter out an unsupported configuration - heap profiling on OS X. if os == 'osx' and '--enable-prof' in configure_flags: continue env_string = '{} COMPILER_FLAGS="{}" CONFIGURE_FLAGS="{}"'.format( compilers, " ".join(compiler_flags), " ".join(configure_flags)) include_rows += ' - os: %s\n' % os include_rows += ' env: %s\n' % env_string if '-m32' in unusual_combination and os == 'linux': include_rows += ' addons:\n' include_rows += ' apt:\n' include_rows += ' packages:\n' include_rows += ' - gcc-multilib\n' print travis_template % include_rows
isabella232/turbine-fulcrum
template/src/java/org/apache/fulcrum/template/TemplateService.java
<reponame>isabella232/turbine-fulcrum package org.apache.fulcrum.template; /* * Licensed to the Apache Software Foundation (ASF) under one * or more contributor license agreements. See the NOTICE file * distributed with this work for additional information * regarding copyright ownership. The ASF licenses this file * to you under the Apache License, Version 2.0 (the * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY * KIND, either express or implied. See the License for the * specific language governing permissions and limitations * under the License. */ import java.io.OutputStream; import java.io.Writer; /** * This service provides a method for mapping templates to their * appropriate Screens or Navigations. It also allows templates to * define a layout/navigations/screen modularization within the * template structure. It also performs caching if turned on in the * properties file. * * @author <a href="mailto:<EMAIL>"><NAME></a> * @author <a href="mailto:<EMAIL>"><NAME></a> * @author <a href="mailto:<EMAIL>"><NAME></a> * @author <a href="mailto:<EMAIL>"><NAME></a> * @version $Id$ */ public interface TemplateService { String ROLE = TemplateService.class.getName(); /** * The key to the template context. */ public static final String CONTEXT = "TEMPLATE_CONTEXT"; /** * Translates the supplied template paths into their Turbine-canonical * equivalent (probably absolute paths). * * @param templatePaths An array of template paths. * @return An array of translated template paths. */ public String[] translateTemplatePaths(String[] templatePaths); /** * Delegates to the appropriate {@link * org.apache.fulcrum.template.TemplateEngineService} to * check the existance of the specified template. * * @param template The template to check for the existance of. * @param templatePaths The paths to check for the template. */ public boolean templateExists(String template, String[] templatePaths); /** * Registers the provided template engine for use by the * <code>TemplateService</code>. * * @param service The <code>TemplateEngineService</code> to register. */ public void registerTemplateEngineService(TemplateEngineService service); public String handleRequest(TemplateContext context, String template) throws TemplateException; public void handleRequest(TemplateContext context, String template, OutputStream outputStream) throws TemplateException; public void handleRequest(TemplateContext context, String template, Writer writer) throws TemplateException; public TemplateContext getTemplateContext(); public boolean templateExists(String template); }
synapticarbors/wagyu
wagyu/edge.py
import math from typing import Optional from reprit.base import generate_repr from .hints import Coordinate from .point import Point from .utils import (round_towards_max, round_towards_min) class Edge: __slots__ = 'top', 'bottom', 'slope' def __init__(self, bottom: Point, top: Point) -> None: self.bottom, self.top = ((top, bottom) if bottom.y < top.y else (bottom, top)) dy = self.top.y - self.bottom.y self.slope = (self.top.x - self.bottom.x) / dy if dy else math.inf __repr__ = generate_repr(__init__) def __and__(self, other: 'Edge') -> Optional[Point]: delta_x = self.top.x - self.bottom.x delta_y = self.top.y - self.bottom.y other_delta_x = other.top.x - other.bottom.x other_delta_y = other.top.y - other.bottom.y denominator = delta_x * other_delta_y - other_delta_x * delta_y if not denominator: return None s = ((-delta_y * (self.bottom.x - other.bottom.x) + delta_x * (self.bottom.y - other.bottom.y)) / denominator) t = ((other_delta_x * (self.bottom.y - other.bottom.y) - other_delta_y * (self.bottom.x - other.bottom.x)) / denominator) return (Point(self.bottom.x + (t * delta_x), self.bottom.y + (t * delta_y)) if 0. <= s <= 1. and 0. <= t <= 1. else None) def __eq__(self, other: 'Edge') -> bool: return (self.top == other.top and self.bottom == other.bottom if isinstance(other, Edge) else NotImplemented) @property def is_horizontal(self) -> bool: return math.isinf(self.slope) def get_current_x(self, current_y: Coordinate) -> Coordinate: return float( self.top.x if current_y == self.top.y else self.bottom.x + self.slope * (current_y - self.bottom.y)) def get_min_x(self, current_y: Coordinate) -> Coordinate: if self.is_horizontal: return min(self.bottom.x, self.top.x) elif self.slope > 0: if current_y == self.top.y: return self.top.x else: lower_range_y = current_y - self.bottom.y - 0.5 return round_towards_min(self.bottom.x + self.slope * lower_range_y) elif current_y == self.bottom.y: return self.bottom.x else: lower_range_y = current_y - self.bottom.y + 0.5 return round_towards_min(self.bottom.x + self.slope * lower_range_y) def get_max_x(self, current_y: Coordinate) -> Coordinate: if self.is_horizontal: return max(self.bottom.x, self.top.x) elif self.slope < 0: if current_y == self.top.y: return self.top.x else: lower_range_y = current_y - self.bottom.y - 0.5 return round_towards_max(self.bottom.x + self.slope * lower_range_y) elif current_y == self.bottom.y: return self.bottom.x else: lower_range_y = current_y - self.bottom.y + 0.5 return round_towards_max(self.bottom.x + self.slope * lower_range_y) def reverse_horizontal(self) -> None: self.top, self.bottom = (Point(self.bottom.x, self.top.y), Point(self.top.x, self.bottom.y)) def are_edges_slopes_equal(first: Edge, second: Edge) -> bool: return ((first.top.y - first.bottom.y) * (second.top.x - second.bottom.x) == ((first.top.x - first.bottom.x) * (second.top.y - second.bottom.y)))
olegon/online-judges
uri-online-judge/1309/main.cpp
/* Formatação Monetária https://www.urionlinejudge.com.br/judge/pt/problems/view/1309 */ #include <iostream> #include <iomanip> using namespace std; void printCurrency(int dollars, int cents); void printDollars(int dollars); void printCents(int cents); int main(void) { ios::sync_with_stdio(false); int dollars, cents; while (cin >> dollars >> cents) { printCurrency(dollars, cents); } return 0; } void printCurrency(int dollars, int cents) { printDollars(dollars); printCents(cents); } void printDollars(int dollars) { if (dollars < 1000) { cout << '$' << dollars; } else { printDollars(dollars / 1000); cout << ',' << setw(3) << setfill('0') << (dollars % 1000); } } void printCents(int cents) { cout << '.' << setw(2) << setfill('0') << cents << endl; }
tiagolobocastro/goNes
lib/mappers/cartridge.go
<gh_stars>1-10 package mappers import ( "encoding/binary" "fmt" "github.com/tiagolobocastro/gones/lib/ppu" "io" "log" "os" "path/filepath" "github.com/tiagolobocastro/gones/lib/common" "github.com/tiagolobocastro/gones/lib/cpu" ) const ( mapperNROM = iota mapperMMC1 mapperUnROM mapperMMC2 ) type NesView interface { PPU() *ppu.Ppu CPU() *cpu.Cpu } type Mapper interface { common.BusInt Init() Tick() } var CartEndianness = binary.LittleEndian func (c *Cartridge) defaultInit() error { c.prgRom.Init(16384*4, true) c.chr.Init(16384, true) c.ram.Init(16384) c.Mapper = c.newCartMapper(mapperNROM) return nil } func (c *Cartridge) Init(cartPath string, nes NesView) error { c.nes = nes c.cart = cartPath c.prgRom = new(common.Rom) c.prgRam = new(common.Ram) c.chr = new(common.Rom) c.ram = new(common.Ram) if c.cart == "" { // current go tests do not use a cartridge but rather just // soft load code on demand return c.defaultInit() } file, err := os.Open(c.cart) if err != nil { return err } defer func() { err := file.Close() if err != nil { log.Printf("error closing file:%v\nbut ignoring it since it's we didn't write anything...", err) } }() header := iNESHeader{} if err := binary.Read(file, CartEndianness, &header); err != nil { return err } c.config, err = header.Config() if err != nil { return err } if c.config.console != consoleNES { log.Panicf("Unsupported console type %v", c.config.console) } if c.config.trainer { trainer := make([]byte, 512) if _, err = io.ReadFull(file, trainer); err != nil { return err } } c.prgRom.Init(c.config.prgRomSize, false) if _, err = c.prgRom.LoadFromFile(file); err != nil { return err } c.prgRam.Init(c.config.prgRamSize) if c.config.battery { c.prgRam.LoadFromFile(c.getRamSaveFile()) } // todo: when is this "rom" writable?? c.chr.Init(c.config.chrRomSize, true) if _, err = c.chr.LoadFromFile(file); err != nil { return err } if c.config.chrRomSize == 0 { c.chr.Init(0x4000, true) } c.Mapper = c.newCartMapper(c.config.mapper) c.Mapper.Init() c.Tables.Init(common.NameTableMirroring(c.config.mirror)) return nil } func (c *Cartridge) Ticks(nTicks int) { for i := 0; i < nTicks; i++ { c.Mapper.Tick() } } func (c *Cartridge) Stop() { if c.config.battery { if err := c.prgRam.SaveToFile(c.getRamSaveFile()); err != nil { log.Panicf("Failed to save game: %v", err) } } } func (c *Cartridge) Reset() { c.Init(c.cart, c.nes) } func (c *Cartridge) Serialise(s common.Serialiser) error { return s.Serialise(c.prgRom, c.prgRam, c.chr, c.ram, &c.Tables, c.Mapper) } func (c *Cartridge) DeSerialise(s common.Serialiser) error { return s.DeSerialise(c.prgRom, c.prgRam, c.chr, c.ram, &c.Tables, c.Mapper) } func (c *Cartridge) newCartMapper(mapper byte) Mapper { switch mapper { case 0: return &MapperNROM{cart: c} case 1: return &MapperMMC1{cart: c} case 2, 9: return &MapperMMC2{cart: c} case 4: return &MapperMMC3{cart: c} default: panic(fmt.Sprintf("mapper %v not supported!", mapper)) } } func (c *Cartridge) SetMirroring(mirroring common.NameTableMirroring) { c.Tables.Mirroring = mirroring } func (c *Cartridge) WriteRom16(addr uint16, val uint16) { c.prgRom.Write16(addr, val) } // must be called after the prgRom is loaded func (c *Cartridge) getRamSaveFile() *os.File { homeDir, err := os.UserHomeDir() if err != nil { log.Panicf("Failed to get user homedir: %v", err) } _, romName := filepath.Split(c.cart) // adding a a hash of the prgRom to help since I tend to use tmp images ("a.nes") for debugging ease saveFolder := fmt.Sprintf("%s/.config/gones", homeDir) save := fmt.Sprintf("%s/%s_%x", saveFolder, romName, c.prgRom.Hash()) if _, err := os.Stat(save); os.IsNotExist(err) { if err := os.MkdirAll(saveFolder, 0700); err != nil { log.Panicf("Failed to create save folder: %v", err) } f, err := os.Create(save) if err != nil { log.Panicf("Failed to create save file: %v", err) } f.Close() } f, err := os.Open(save) if err != nil { log.Panicf("Failed to open save file: %v", err) } return f } func (c *Cartridge) GetStateSaveFile() *os.File { homeDir, err := os.UserHomeDir() if err != nil { log.Panicf("Failed to get user homedir: %v", err) } _, romName := filepath.Split(c.cart) // adding a a hash of the prgRom to help since I tend to use tmp images ("a.nes") for debugging ease saveFolder := fmt.Sprintf("%s/.config/gones", homeDir) save := fmt.Sprintf("%s/%s_%x", saveFolder, romName, c.prgRom.Hash()) if _, err := os.Stat(save); os.IsNotExist(err) { if err := os.MkdirAll(saveFolder, 0700); err != nil { log.Panicf("Failed to create save folder: %v", err) } f, err := os.Create(save) if err != nil { log.Panicf("Failed to create state save file: %v", err) } f.Close() } f, err := os.OpenFile(save, os.O_CREATE|os.O_RDWR, os.ModeExclusive) if err != nil { log.Panicf("Failed to open state save file: %v", err) } return f } // BusInt type Cartridge struct { nes NesView config iNESConfig version iNESFormat cart string prgRom *common.Rom prgRam *common.Ram chr *common.Rom ram *common.Ram Tables common.NameTables Mapper Mapper }
riteshkumar99/coding-for-placement
leetcode/problemset-algorithms/smallest-subtree-with-all-the-deepest-nodes.cpp
class Solution { public: int recur(TreeNode *node, TreeNode * &ans) { int leftLen, rightLen; // we store the max length of left and right subtree in these vars TreeNode *leftNode, *rightNode; // we store the ans for left and right subtree in these vars if(node->left == NULL && node->right == NULL) { // current node is leaf node, then this is present answer ans = node; return 1; } else if(node->left == NULL) { // left subtree is NULL, hence, answer will be same as right subtree return 1 + recur(node->right, ans); } else if(node->right == NULL) { // right subtree is NULL, hence, answer will be same as left subtree return 1 + recur(node->left, ans); } else { // both left and right subtree are not NULL leftLen = 1 + recur(node->left, leftNode); // find max depth of left subtree and corresponding answer rightLen = 1 + recur(node->right, rightNode); // find max depth of right subtree and corresponding answer if(leftLen == rightLen) { // this makes current node as potential answer ans = node; return leftLen; } else if(leftLen > rightLen) { // left child node is potential answer ans = leftNode; return leftLen; } else { // right child node is potential answer ans = rightNode; return rightLen; } } } TreeNode* subtreeWithAllDeepest(TreeNode* root) { TreeNode *ans = NULL; if(root == NULL) return ans; // store answer to the problem in variable ans recur(root, ans); return ans; } };
jinlongliu/AliOS-Things
platform/mcu/rda8955/inc/chip/regs/include/bb_cp2_asm.h
/* Copyright (C) 2016 RDA Technologies Limited and/or its affiliates("RDA"). * All rights reserved. * * This software is supplied "AS IS" without any warranties. * RDA assumes no responsibility or liability for the use of the software, * conveys no license or title under any patent, copyright, or mask work * right to the product. RDA reserves the right to make changes in the * software without notification. RDA also make no representation or * warranty that such application will be suitable for the specified use * without further testing or modification. */ #ifndef _BB_CP2_ASM_H_ #define _BB_CP2_ASM_H_ //THIS FILE HAS BEEN GENERATED WITH COOLWATCHER. PLEASE EDIT WITH CARE ! #ifndef CT_ASM #error "You are trying to use in a normal C code the assembly H description of 'bb_cp2'." #endif //============================================================================== // bb_cp2 //------------------------------------------------------------------------------ /// //============================================================================== #define REG_BB_CP2_BASE 0x01908000 #define REG_BB_CP2_BASE_HI BASE_HI(REG_BB_CP2_BASE) #define REG_BB_CP2_BASE_LO BASE_LO(REG_BB_CP2_BASE) #define REG_BB_CP2_CTRL REG_BB_CP2_BASE_LO + 0x00000000 #define REG_BB_CP2_BIT_NUMBER REG_BB_CP2_BASE_LO + 0x00000004 #define REG_BB_CP2_STATUS REG_BB_CP2_BASE_LO + 0x00000008 #define REG_BB_CP2_LRAM_ADDR REG_BB_CP2_BASE_LO + 0x0000000C #define REG_BB_CP2_CRC_CODE_LSB REG_BB_CP2_BASE_LO + 0x00000010 #define REG_BB_CP2_CRC_CODE_MSB REG_BB_CP2_BASE_LO + 0x00000014 #define REG_BB_CP2_CP2_SELECT REG_BB_CP2_BASE_LO + 0x0000007C #define REG_BB_CP2_LRAM_DATA REG_BB_CP2_BASE_LO + 0x00000080 //ctrl #define BB_CP2_FIRST_POLY(n) (((n)&7)<<0) #define BB_CP2_SECOND_POLY(n) (((n)&7)<<3) #define BB_CP2_THIRD_POLY(n) (((n)&7)<<6) #define BB_CP2_FOURTH_POLY(n) (((n)&7)<<9) #define BB_CP2_FITH_POLY(n) (((n)&7)<<12) #define BB_CP2_SIXTH_POLY(n) (((n)&7)<<15) #define BB_CP2_RSC_POLY(n) (((n)&7)<<18) #define BB_CP2_NB_POLY(n) (((n)&7)<<21) #define BB_CP2_ENABLE_PUNCTURING (1<<24) //bit_number #define BB_CP2_BIT_NUMBER(n) (((n)&0x1FF)<<0) //Status #define BB_CP2_ENABLE (1<<0) //lram_addr #define BB_CP2_LRAM_ADDRESS(n) (((n)&31)<<0) #define BB_CP2_LRAM_SELECT (1<<5) //CRC_code_LSB #define BB_CP2_CRC_LSB_CODE(n) (((n)&0xFFFFFFFF)<<0) //CRC_code_MSB #define BB_CP2_CRC_MSB_CODE(n) (((n)&0xFF)<<0) //CP2_Select #define BB_CP2_CP2_SELECT (1<<0) //LRAM_Data #define BB_CP2_LRAM_DATA(n) (((n)&0xFFFFFFFF)<<0) #endif
guoliim/resume-by-react
lib/views2/components/ExpList.js
import React from 'react' import PropTypes from 'prop-types' import Label from './Label' import Exp from './Exp' const ExpList = ({ exps = [] }) => { return ( <div className="exps"> <Label title={'个人项目实践'} url={'./img/ic_explore_24px.svg'} alt={'个人项目实践'}/> {exps.map((exp) => ( <Exp {...exp} key={exp.item} /> ))} </div> ) } ExpList.propTypes = { exps: PropTypes.array, } export default ExpList
puzzle/nochmal
spec/dummy/vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/lib/sassc/importer.rb
# frozen_string_literal: true module SassC class Importer attr_reader :options def initialize(options) @options = options end def imports(path, parent_path) # A custom importer must override this method. # Custom importer may return an Import, or an array of Imports. raise NotImplementedError end class Import attr_accessor :path, :source, :source_map_path def initialize(path, source: nil, source_map_path: nil) @path = path @source = source @source_map_path = source_map_path end def to_s "Import: #{path} #{source} #{source_map_path}" end end end end
Qwertygiy/Scenario
src/main/java/org/terasology/scenario/components/ScenarioComponent.java
<filename>src/main/java/org/terasology/scenario/components/ScenarioComponent.java /* * Copyright 2017 MovingBlocks * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package org.terasology.scenario.components; import org.terasology.entitySystem.Component; import org.terasology.entitySystem.entity.EntityRef; import org.terasology.math.Region3i; import org.terasology.network.FieldReplicateType; import org.terasology.network.NetworkComponent; import org.terasology.network.Replicate; import org.terasology.scenario.components.regions.RegionBeingCreatedComponent; import org.terasology.scenario.components.regions.RegionColorComponent; import org.terasology.scenario.components.regions.RegionContainingEntitiesComponent; import org.terasology.scenario.components.regions.RegionLocationComponent; import org.terasology.scenario.components.regions.RegionNameComponent; import org.terasology.scenario.internal.systems.RegionSystem; import org.terasology.structureTemplates.components.ProtectedRegionsComponent; import org.terasology.scenario.components.actions.ScenarioIndicatorActionComponent; import org.terasology.scenario.components.actions.ScenarioSecondaryGiveBlockComponent; import java.util.ArrayList; import java.util.List; /** * Component that indicates an entity is the root scenario entity. Only one entity with this component should exist at a time. * Trigger entities list contain a list of triggers that each have a list of logic entities * Region entities list contains a list of all the region entities * * Argument entities are detailed in {@link ScenarioArgumentContainerComponent} * * Typical Scenario logic entities include: * Network Component - This is just the default network component for a terasology entity {@link NetworkComponent} * Indicator Component - This is a component that indicates the general type of the entity(Action/Event/Condition), example is {@link ScenarioIndicatorActionComponent} * {@link ScenarioLogicLabelComponent} - label field includes the text for the dropdown menus * Secondary Component - This is a component that indicates the specific type of the entity, so if it is an action the secondary (indicator) could denote that is is specifically * a "give block" action, example being {@link ScenarioSecondaryGiveBlockComponent} * *{@link ScenarioLogicTextComponent} - text field is the text that is displayed with arguments included (Detailed in the class) * *{@link ScenarioArgumentContainerComponent} - Only needed if the entity description includes argument parameters * * * is not required * * Region entities include: * Network Component - This is just the default network component for a terasology entity {@link NetworkComponent} * {@link RegionNameComponent} Component - field indicates the name of the region * {@link RegionColorComponent} Component - field indicates the color of the region * {@link RegionContainingEntitiesComponent} Component - field contains a list that is monitored by {@link RegionSystem} of what player entities are within the region * {@link RegionLocationComponent} Component - field is the actual region in the world as a {@link Region3i} * * {@link RegionBeingCreatedComponent} Component * * {@link ProtectedRegionsComponent} * * * indicates optional (RegionBeingCreated meaning it is currently being created, ProtectedRegion meaning the region * is being protected by the structureTemplates system and will prevent alterations being made to the land within the region */ public class ScenarioComponent implements Component { @Replicate(FieldReplicateType.SERVER_TO_CLIENT) public List<EntityRef> triggerEntities = new ArrayList<>(); @Replicate(FieldReplicateType.SERVER_TO_CLIENT) public List<EntityRef> regionEntities = new ArrayList<>(); }
xmutzlq/ZZ
BopZZ/gen/com/bop/zz/R.java
<gh_stars>1-10 /* AUTO-GENERATED FILE. DO NOT MODIFY. * * This class was automatically generated by the * aapt tool from the resource data it found. It * should not be modified by hand. */ package com.bop.zz; public final class R { public static final class anim { public static final int arrow_right=0x7f050000; public static final int arrow_up=0x7f050001; public static final int bs_list_item_in=0x7f050002; public static final int bs_list_layout_anim_in=0x7f050003; public static final int decelerate_cubic=0x7f050004; public static final int dialog_enter=0x7f050005; public static final int dialog_enter_center=0x7f050006; public static final int dialog_exit=0x7f050007; public static final int dialog_exit_center=0x7f050008; public static final int dock_bottom_enter=0x7f050009; public static final int dock_bottom_exit=0x7f05000a; public static final int gf_flip_horizontal_in=0x7f05000b; public static final int gf_flip_horizontal_out=0x7f05000c; public static final int popup_enter=0x7f05000d; public static final int popup_exit=0x7f05000e; public static final int slide_in_from_bottom=0x7f05000f; public static final int slide_out_to_bottom=0x7f050010; } public static final class array { public static final int load_more_style=0x7f0c0001; public static final int showGuidelinesArray=0x7f0c0000; } public static final class attr { /** <p>May be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or "<code>#<i>aarrggbb</i></code>". */ public static final int actionSheetBackground=0x7f010020; /** <p>May be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". <p>May be a dimension value, which is a floating point number appended with a unit such as "<code>14.5sp</code>". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), mm (millimeters). */ public static final int actionSheetPadding=0x7f010028; /** <p>Must be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". */ public static final int actionSheetStyle=0x7f01001f; /** <p>May be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". <p>May be a dimension value, which is a floating point number appended with a unit such as "<code>14.5sp</code>". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), mm (millimeters). */ public static final int actionSheetTextSize=0x7f01002b; /** <p>Must be one of the following constant values.</p> <table> <colgroup align="left" /> <colgroup align="left" /> <colgroup align="left" /> <tr><th>Constant</th><th>Value</th><th>Description</th></tr> <tr><td><code>none</code></td><td>-1</td><td></td></tr> <tr><td><code>fitXY</code></td><td>0</td><td></td></tr> <tr><td><code>fitStart</code></td><td>1</td><td></td></tr> <tr><td><code>fitCenter</code></td><td>2</td><td></td></tr> <tr><td><code>fitEnd</code></td><td>3</td><td></td></tr> <tr><td><code>center</code></td><td>4</td><td></td></tr> <tr><td><code>centerInside</code></td><td>5</td><td></td></tr> <tr><td><code>centerCrop</code></td><td>6</td><td></td></tr> <tr><td><code>focusCrop</code></td><td>7</td><td></td></tr> </table> */ public static final int actualImageScaleType=0x7f010010; /** <p>Must be a string value, using '\\;' to escape characters such as '\\n' or '\\uxxxx' for a unicode character. <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. */ public static final int actualImageUri=0x7f01001e; /** <p>Must be an integer value, such as "<code>100</code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. */ public static final int aspectRatioX=0x7f010002; /** <p>Must be an integer value, such as "<code>100</code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. */ public static final int aspectRatioY=0x7f010003; /** <p>Must be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". */ public static final int backgroundImage=0x7f010011; /** <p>Must be a dimension value, which is a floating point number appended with a unit such as "<code>14.5sp</code>". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), mm (millimeters). <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. */ public static final int bar_length=0x7f010060; /** <p>Must be a boolean value, either "<code>true</code>" or "<code>false</code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. */ public static final int bar_orientation_horizontal=0x7f010063; /** <p>Must be a dimension value, which is a floating point number appended with a unit such as "<code>14.5sp</code>". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), mm (millimeters). <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. */ public static final int bar_pointer_halo_radius=0x7f010062; /** <p>Must be a dimension value, which is a floating point number appended with a unit such as "<code>14.5sp</code>". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), mm (millimeters). <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. */ public static final int bar_pointer_radius=0x7f010061; /** <p>Must be a dimension value, which is a floating point number appended with a unit such as "<code>14.5sp</code>". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), mm (millimeters). <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. */ public static final int bar_thickness=0x7f01005f; /** <p>Must be a color value, in the form of "<code>#<i>rgb</i></code>", "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or "<code>#<i>aarrggbb</i></code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. */ public static final int border_color=0x7f010042; /** <p>Must be a dimension value, which is a floating point number appended with a unit such as "<code>14.5sp</code>". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), mm (millimeters). <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. */ public static final int border_width=0x7f010041; /** <p>Must be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". */ public static final int bs_bottomSheetStyle=0x7f010043; /** <p>Must be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". */ public static final int bs_closeDrawable=0x7f01004d; /** <p>Must be a boolean value, either "<code>true</code>" or "<code>false</code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. */ public static final int bs_collapseListIcons=0x7f01004e; /** <p>May be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or "<code>#<i>aarrggbb</i></code>". */ public static final int bs_dialogBackground=0x7f010044; /** <p>May be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or "<code>#<i>aarrggbb</i></code>". */ public static final int bs_dividerColor=0x7f010046; /** <p>Must be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". */ public static final int bs_gridItemLayout=0x7f010050; /** <p>Must be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". */ public static final int bs_gridItemTitleTextAppearance=0x7f01004a; /** <p>Must be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". */ public static final int bs_headerLayout=0x7f010051; /** <p>Must be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". */ public static final int bs_listItemLayout=0x7f01004f; /** <p>Must be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". */ public static final int bs_listItemTitleTextAppearance=0x7f010049; /** <p>Must be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". */ public static final int bs_listStyle=0x7f010045; /** <p>Must be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". */ public static final int bs_moreDrawable=0x7f01004b; /** <p>Must be a string value, using '\\;' to escape characters such as '\\n' or '\\uxxxx' for a unicode character. <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. */ public static final int bs_moreText=0x7f01004c; /** <p>Must be an integer value, such as "<code>100</code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. */ public static final int bs_numColumns=0x7f010047; /** <p>Must be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". */ public static final int bs_titleTextAppearance=0x7f010048; /** <p>May be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or "<code>#<i>aarrggbb</i></code>". */ public static final int cancelButtonBackground=0x7f010021; /** <p>May be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". <p>May be a dimension value, which is a floating point number appended with a unit such as "<code>14.5sp</code>". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), mm (millimeters). */ public static final int cancelButtonMarginTop=0x7f01002a; /** <p>May be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or "<code>#<i>aarrggbb</i></code>". */ public static final int cancelButtonTextColor=0x7f010026; /** Background color for CardView. 背景色 <p>Must be a color value, in the form of "<code>#<i>rgb</i></code>", "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or "<code>#<i>aarrggbb</i></code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. */ public static final int cardBackgroundColor=0x7f010033; /** Corner radius for CardView. 边缘弧度数 <p>Must be a dimension value, which is a floating point number appended with a unit such as "<code>14.5sp</code>". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), mm (millimeters). <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. */ public static final int cardCornerRadius=0x7f010034; /** Elevation for CardView. 高度 <p>Must be a dimension value, which is a floating point number appended with a unit such as "<code>14.5sp</code>". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), mm (millimeters). <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. */ public static final int cardElevation=0x7f010035; /** Maximum Elevation for CardView. 最大高度 <p>Must be a dimension value, which is a floating point number appended with a unit such as "<code>14.5sp</code>". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), mm (millimeters). <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. */ public static final int cardMaxElevation=0x7f010036; /** Add padding to CardView on v20 and before to prevent intersections between the Card content and rounded corners. 在v20和之前的版本中添加内边距,这个属性是为了防止卡片内容和边角的重叠 <p>Must be a boolean value, either "<code>true</code>" or "<code>false</code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. */ public static final int cardPreventCornerOverlap=0x7f010038; /** Add padding in API v21+ as well to have the same measurements with previous versions. 设置内边距,v21+的版本和之前的版本仍旧具有一样的计算方式 <p>Must be a boolean value, either "<code>true</code>" or "<code>false</code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. */ public static final int cardUseCompatPadding=0x7f010037; /** <p>Must be a dimension value, which is a floating point number appended with a unit such as "<code>14.5sp</code>". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), mm (millimeters). <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. */ public static final int color_center_halo_radius=0x7f01005c; /** <p>Must be a dimension value, which is a floating point number appended with a unit such as "<code>14.5sp</code>". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), mm (millimeters). <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. */ public static final int color_center_radius=0x7f01005b; /** <p>Must be a dimension value, which is a floating point number appended with a unit such as "<code>14.5sp</code>". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), mm (millimeters). <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. */ public static final int color_pointer_halo_radius=0x7f01005e; /** <p>Must be a dimension value, which is a floating point number appended with a unit such as "<code>14.5sp</code>". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), mm (millimeters). <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. */ public static final int color_pointer_radius=0x7f01005d; /** <p>Must be a dimension value, which is a floating point number appended with a unit such as "<code>14.5sp</code>". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), mm (millimeters). <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. */ public static final int color_wheel_radius=0x7f010059; /** <p>Must be a dimension value, which is a floating point number appended with a unit such as "<code>14.5sp</code>". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), mm (millimeters). <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. */ public static final int color_wheel_thickness=0x7f01005a; /** 下面是卡片边界距离内部的距离 Inner padding between the edges of the Card and children of the CardView. <p>Must be a dimension value, which is a floating point number appended with a unit such as "<code>14.5sp</code>". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), mm (millimeters). <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. */ public static final int contentPadding=0x7f010039; /** Inner padding between the bottom edge of the Card and children of the CardView. <p>Must be a dimension value, which is a floating point number appended with a unit such as "<code>14.5sp</code>". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), mm (millimeters). <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. */ public static final int contentPaddingBottom=0x7f01003d; /** Inner padding between the left edge of the Card and children of the CardView. <p>Must be a dimension value, which is a floating point number appended with a unit such as "<code>14.5sp</code>". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), mm (millimeters). <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. */ public static final int contentPaddingLeft=0x7f01003a; /** Inner padding between the right edge of the Card and children of the CardView. <p>Must be a dimension value, which is a floating point number appended with a unit such as "<code>14.5sp</code>". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), mm (millimeters). <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. */ public static final int contentPaddingRight=0x7f01003b; /** Inner padding between the top edge of the Card and children of the CardView. <p>Must be a dimension value, which is a floating point number appended with a unit such as "<code>14.5sp</code>". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), mm (millimeters). <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. */ public static final int contentPaddingTop=0x7f01003c; /** <p>Must be a dimension value, which is a floating point number appended with a unit such as "<code>14.5sp</code>". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), mm (millimeters). <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. */ public static final int dividerWidth=0x7f010030; /** <p>Must be a color value, in the form of "<code>#<i>rgb</i></code>", "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or "<code>#<i>aarrggbb</i></code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. */ public static final int fabColorNormal=0x7f01002d; /** <p>Must be a color value, in the form of "<code>#<i>rgb</i></code>", "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or "<code>#<i>aarrggbb</i></code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. */ public static final int fabColorPressed=0x7f01002c; /** <p>Must be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". */ public static final int fabIcon=0x7f01002e; /** <p>Must be a string value, using '\\;' to escape characters such as '\\n' or '\\uxxxx' for a unicode character. <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. */ public static final int fabTitle=0x7f01002f; /** <p>Must be an integer value, such as "<code>100</code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. */ public static final int fadeDuration=0x7f010005; /** <p>Must be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". */ public static final int failureImage=0x7f01000b; /** <p>Must be one of the following constant values.</p> <table> <colgroup align="left" /> <colgroup align="left" /> <colgroup align="left" /> <tr><th>Constant</th><th>Value</th><th>Description</th></tr> <tr><td><code>none</code></td><td>-1</td><td></td></tr> <tr><td><code>fitXY</code></td><td>0</td><td></td></tr> <tr><td><code>fitStart</code></td><td>1</td><td></td></tr> <tr><td><code>fitCenter</code></td><td>2</td><td></td></tr> <tr><td><code>fitEnd</code></td><td>3</td><td></td></tr> <tr><td><code>center</code></td><td>4</td><td></td></tr> <tr><td><code>centerInside</code></td><td>5</td><td></td></tr> <tr><td><code>centerCrop</code></td><td>6</td><td></td></tr> <tr><td><code>focusCrop</code></td><td>7</td><td></td></tr> </table> */ public static final int failureImageScaleType=0x7f01000c; /** <p>Must be a boolean value, either "<code>true</code>" or "<code>false</code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. */ public static final int fixAspectRatio=0x7f010001; /** <p>Must be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". */ public static final int gif=0x7f01003e; /** <p>Must be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". */ public static final int gifMoviewViewStyle=0x7f010040; /** <p>Must be one of the following constant values.</p> <table> <colgroup align="left" /> <colgroup align="left" /> <colgroup align="left" /> <tr><th>Constant</th><th>Value</th><th>Description</th></tr> <tr><td><code>on</code></td><td>2</td><td></td></tr> <tr><td><code>onTouch</code></td><td>1</td><td></td></tr> <tr><td><code>off</code></td><td>0</td><td></td></tr> </table> */ public static final int guidelines=0x7f010000; /** <p>Must be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". */ public static final int imageResource=0x7f010004; /** <p>Must be one or more (separated by '|') of the following constant values.</p> <table> <colgroup align="left" /> <colgroup align="left" /> <colgroup align="left" /> <tr><th>Constant</th><th>Value</th><th>Description</th></tr> <tr><td><code>BallPulse</code></td><td>0</td><td></td></tr> <tr><td><code>BallGridPulse</code></td><td>1</td><td></td></tr> <tr><td><code>BallClipRotate</code></td><td>2</td><td></td></tr> <tr><td><code>BallClipRotatePulse</code></td><td>3</td><td></td></tr> <tr><td><code>SquareSpin</code></td><td>4</td><td></td></tr> <tr><td><code>BallClipRotateMultiple</code></td><td>5</td><td></td></tr> <tr><td><code>BallPulseRise</code></td><td>6</td><td></td></tr> <tr><td><code>BallRotate</code></td><td>7</td><td></td></tr> <tr><td><code>CubeTransition</code></td><td>8</td><td></td></tr> <tr><td><code>BallZigZag</code></td><td>9</td><td></td></tr> <tr><td><code>BallZigZagDeflect</code></td><td>10</td><td></td></tr> <tr><td><code>BallTrianglePath</code></td><td>11</td><td></td></tr> <tr><td><code>BallScale</code></td><td>12</td><td></td></tr> <tr><td><code>LineScale</code></td><td>13</td><td></td></tr> <tr><td><code>LineScaleParty</code></td><td>14</td><td></td></tr> <tr><td><code>BallScaleMultiple</code></td><td>15</td><td></td></tr> <tr><td><code>BallPulseSync</code></td><td>16</td><td></td></tr> <tr><td><code>BallBeat</code></td><td>17</td><td></td></tr> <tr><td><code>LineScalePulseOut</code></td><td>18</td><td></td></tr> <tr><td><code>LineScalePulseOutRapid</code></td><td>19</td><td></td></tr> <tr><td><code>BallScaleRipple</code></td><td>20</td><td></td></tr> <tr><td><code>BallScaleRippleMultiple</code></td><td>21</td><td></td></tr> <tr><td><code>BallSpinFadeLoader</code></td><td>22</td><td></td></tr> <tr><td><code>LineSpinFadeLoader</code></td><td>23</td><td></td></tr> <tr><td><code>TriangleSkewSpin</code></td><td>24</td><td></td></tr> <tr><td><code>Pacman</code></td><td>25</td><td></td></tr> <tr><td><code>BallGridBeat</code></td><td>26</td><td></td></tr> <tr><td><code>SemiCircleSpin</code></td><td>27</td><td></td></tr> </table> */ public static final int indicator=0x7f010031; /** <p>Must be a color value, in the form of "<code>#<i>rgb</i></code>", "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or "<code>#<i>aarrggbb</i></code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. */ public static final int indicator_color=0x7f010032; /** <p>Must be one or more (separated by '|') of the following constant values.</p> <table> <colgroup align="left" /> <colgroup align="left" /> <colgroup align="left" /> <tr><th>Constant</th><th>Value</th><th>Description</th></tr> <tr><td><code>click</code></td><td>0x0</td><td></td></tr> <tr><td><code>scroll</code></td><td>0x1</td><td></td></tr> </table> */ public static final int loadMoreMode=0x7f01006d; /** <p>Must be a string value, using '\\;' to escape characters such as '\\n' or '\\uxxxx' for a unicode character. <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. */ public static final int loadMoreView=0x7f01006e; /** <p>Must be a boolean value, either "<code>true</code>" or "<code>false</code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. */ public static final int noLoadMoreHideView=0x7f01006f; /** <p>May be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or "<code>#<i>aarrggbb</i></code>". */ public static final int otherButtonBottomBackground=0x7f010024; /** <p>May be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or "<code>#<i>aarrggbb</i></code>". */ public static final int otherButtonMiddleBackground=0x7f010023; /** <p>May be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or "<code>#<i>aarrggbb</i></code>". */ public static final int otherButtonSingleBackground=0x7f010025; /** <p>May be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". <p>May be a dimension value, which is a floating point number appended with a unit such as "<code>14.5sp</code>". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), mm (millimeters). */ public static final int otherButtonSpacing=0x7f010029; /** <p>May be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or "<code>#<i>aarrggbb</i></code>". */ public static final int otherButtonTextColor=0x7f010027; /** <p>May be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or "<code>#<i>aarrggbb</i></code>". */ public static final int otherButtonTopBackground=0x7f010022; /** <p>Must be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". */ public static final int overlayImage=0x7f010012; /** <p>Must be a boolean value, either "<code>true</code>" or "<code>false</code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. */ public static final int paused=0x7f01003f; /** <p>Must be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". */ public static final int placeholderImage=0x7f010007; /** <p>Must be one of the following constant values.</p> <table> <colgroup align="left" /> <colgroup align="left" /> <colgroup align="left" /> <tr><th>Constant</th><th>Value</th><th>Description</th></tr> <tr><td><code>none</code></td><td>-1</td><td></td></tr> <tr><td><code>fitXY</code></td><td>0</td><td></td></tr> <tr><td><code>fitStart</code></td><td>1</td><td></td></tr> <tr><td><code>fitCenter</code></td><td>2</td><td></td></tr> <tr><td><code>fitEnd</code></td><td>3</td><td></td></tr> <tr><td><code>center</code></td><td>4</td><td></td></tr> <tr><td><code>centerInside</code></td><td>5</td><td></td></tr> <tr><td><code>centerCrop</code></td><td>6</td><td></td></tr> <tr><td><code>focusCrop</code></td><td>7</td><td></td></tr> </table> */ public static final int placeholderImageScaleType=0x7f010008; /** <p>Must be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". */ public static final int pressedStateOverlayImage=0x7f010013; /** <p>Must be an integer value, such as "<code>100</code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. */ public static final int progressBarAutoRotateInterval=0x7f01000f; /** <p>Must be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". */ public static final int progressBarImage=0x7f01000d; /** <p>Must be one of the following constant values.</p> <table> <colgroup align="left" /> <colgroup align="left" /> <colgroup align="left" /> <tr><th>Constant</th><th>Value</th><th>Description</th></tr> <tr><td><code>none</code></td><td>-1</td><td></td></tr> <tr><td><code>fitXY</code></td><td>0</td><td></td></tr> <tr><td><code>fitStart</code></td><td>1</td><td></td></tr> <tr><td><code>fitCenter</code></td><td>2</td><td></td></tr> <tr><td><code>fitEnd</code></td><td>3</td><td></td></tr> <tr><td><code>center</code></td><td>4</td><td></td></tr> <tr><td><code>centerInside</code></td><td>5</td><td></td></tr> <tr><td><code>centerCrop</code></td><td>6</td><td></td></tr> <tr><td><code>focusCrop</code></td><td>7</td><td></td></tr> </table> */ public static final int progressBarImageScaleType=0x7f01000e; /** <p>Must be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". */ public static final int ptr_content=0x7f010065; /** <p>Must be an integer value, such as "<code>100</code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. */ public static final int ptr_duration_to_close=0x7f010068; /** <p>Must be an integer value, such as "<code>100</code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. */ public static final int ptr_duration_to_close_header=0x7f010069; /** Optional. If you put header and content in xml, you can you these to specify them. <p>Must be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". */ public static final int ptr_header=0x7f010064; /** keep header when refreshing <p>Must be a boolean value, either "<code>true</code>" or "<code>false</code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. */ public static final int ptr_keep_header_when_refresh=0x7f01006b; /** pull to refresh, otherwise release to refresh, default is release to refresh <p>Must be a boolean value, either "<code>true</code>" or "<code>false</code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. */ public static final int ptr_pull_to_fresh=0x7f01006a; /** the ration of the height of the header to trigger refresh <p>Must be a floating point value, such as "<code>1.2</code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. */ public static final int ptr_ratio_of_header_height_to_refresh=0x7f010067; /** the resistance when you are moving the frame <p>Must be a floating point value, such as "<code>1.2</code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. */ public static final int ptr_resistance=0x7f010066; /** <p>Must be an integer value, such as "<code>100</code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. */ public static final int ptr_rotate_ani_time=0x7f01006c; /** <p>Must be a color value, in the form of "<code>#<i>rgb</i></code>", "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or "<code>#<i>aarrggbb</i></code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. */ public static final int refreshLoadingColor=0x7f010070; /** <p>Must be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". */ public static final int retryImage=0x7f010009; /** <p>Must be one of the following constant values.</p> <table> <colgroup align="left" /> <colgroup align="left" /> <colgroup align="left" /> <tr><th>Constant</th><th>Value</th><th>Description</th></tr> <tr><td><code>none</code></td><td>-1</td><td></td></tr> <tr><td><code>fitXY</code></td><td>0</td><td></td></tr> <tr><td><code>fitStart</code></td><td>1</td><td></td></tr> <tr><td><code>fitCenter</code></td><td>2</td><td></td></tr> <tr><td><code>fitEnd</code></td><td>3</td><td></td></tr> <tr><td><code>center</code></td><td>4</td><td></td></tr> <tr><td><code>centerInside</code></td><td>5</td><td></td></tr> <tr><td><code>centerCrop</code></td><td>6</td><td></td></tr> <tr><td><code>focusCrop</code></td><td>7</td><td></td></tr> </table> */ public static final int retryImageScaleType=0x7f01000a; /** <p>Must be a boolean value, either "<code>true</code>" or "<code>false</code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. */ public static final int roundAsCircle=0x7f010014; /** <p>Must be a boolean value, either "<code>true</code>" or "<code>false</code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. */ public static final int roundBottomLeft=0x7f010019; /** <p>Must be a boolean value, either "<code>true</code>" or "<code>false</code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. */ public static final int roundBottomRight=0x7f010018; /** <p>Must be a boolean value, either "<code>true</code>" or "<code>false</code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. */ public static final int roundTopLeft=0x7f010016; /** <p>Must be a boolean value, either "<code>true</code>" or "<code>false</code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. */ public static final int roundTopRight=0x7f010017; /** <p>Must be a color value, in the form of "<code>#<i>rgb</i></code>", "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or "<code>#<i>aarrggbb</i></code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. */ public static final int roundWithOverlayColor=0x7f01001a; /** <p>Must be a dimension value, which is a floating point number appended with a unit such as "<code>14.5sp</code>". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), mm (millimeters). <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. */ public static final int roundedCornerRadius=0x7f010015; /** <p>Must be a color value, in the form of "<code>#<i>rgb</i></code>", "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or "<code>#<i>aarrggbb</i></code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. */ public static final int roundingBorderColor=0x7f01001c; /** <p>Must be a dimension value, which is a floating point number appended with a unit such as "<code>14.5sp</code>". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), mm (millimeters). <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. */ public static final int roundingBorderPadding=0x7f01001d; /** <p>Must be a dimension value, which is a floating point number appended with a unit such as "<code>14.5sp</code>". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), mm (millimeters). <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. */ public static final int roundingBorderWidth=0x7f01001b; /** <p>May be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". <p>May be a boolean value, either "<code>true</code>" or "<code>false</code>". */ public static final int tbAnimate=0x7f010057; /** <p>May be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". <p>May be a boolean value, either "<code>true</code>" or "<code>false</code>". */ public static final int tbAsDefaultOn=0x7f010058; /** <p>Must be a dimension value, which is a floating point number appended with a unit such as "<code>14.5sp</code>". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), mm (millimeters). <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. */ public static final int tbBorderWidth=0x7f010052; /** <p>May be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or "<code>#<i>aarrggbb</i></code>". */ public static final int tbOffBorderColor=0x7f010053; /** <p>May be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or "<code>#<i>aarrggbb</i></code>". */ public static final int tbOffColor=0x7f010054; /** <p>May be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or "<code>#<i>aarrggbb</i></code>". */ public static final int tbOnColor=0x7f010055; /** <p>May be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or "<code>#<i>aarrggbb</i></code>". */ public static final int tbSpotColor=0x7f010056; /** <p>Must be a floating point value, such as "<code>1.2</code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. */ public static final int viewAspectRatio=0x7f010006; } public static final class color { public static final int alpha_white=0x7f090005; public static final int bg_white=0x7f090025; public static final int black=0x7f090006; public static final int bluegrey=0x7f09002f; public static final int bottom_menu_bg=0x7f09002b; public static final int bs_dark_divider_color=0x7f090029; public static final int bs_divider_color=0x7f090028; public static final int btn_alert=0x7f090021; /** Background color for dark CardView. */ public static final int cardview_dark_background=0x7f090019; /** Background color for light CardView. */ public static final int cardview_light_background=0x7f090018; /** Shadow color for the furthest pixels around CardView. */ public static final int cardview_shadow_end_color=0x7f09001b; /** Shadow color for the first pixels around CardView. */ public static final int cardview_shadow_start_color=0x7f09001a; public static final int colorAccent=0x7f090003; public static final int colorPrimary=0x7f090001; public static final int colorPrimaryDark=0x7f090002; public static final int color_282828=0x7f090007; public static final int color_34aaf3=0x7f09000d; public static final int color_666666=0x7f090008; public static final int color_E5E5E5=0x7f09000b; public static final int color_EDEDED=0x7f09000a; public static final int color_EFEFEF=0x7f09000c; public static final int color_aaaaaa=0x7f090009; public static final int common_bg=0x7f090000; public static final int grey700=0x7f090012; public static final int grey_bg=0x7f090015; public static final int ios7_blue=0x7f09002e; public static final int ios7_gray=0x7f09002d; public static final int ios7_white=0x7f09002c; public static final int ios_btn_normal=0x7f090023; public static final int ios_btn_pressed=0x7f090024; public static final int ios_btntext_blue=0x7f09001c; public static final int line_dd=0x7f090022; public static final int pop_window_bg=0x7f090017; public static final int tab_btn_text=0x7f090030; public static final int text_black=0x7f090016; public static final int text_black_light=0x7f090027; public static final int text_gray=0x7f090013; public static final int text_gray_light=0x7f090026; public static final int text_input_44=0x7f09001f; public static final int text_item_33=0x7f090020; public static final int text_msg_33=0x7f09001e; public static final int text_title_11=0x7f09001d; public static final int toast_bg=0x7f09000e; public static final int toast_fail_bg=0x7f090010; public static final int toast_success_bg=0x7f090011; public static final int toast_success_content=0x7f09000f; public static final int top_bar_bg=0x7f09002a; public static final int txt_gray_light=0x7f090014; public static final int white=0x7f090004; } public static final class dimen { /** Default screen margins, per the Android Design guidelines. Default screen margins, per the Android Design guidelines. */ public static final int activity_horizontal_margin=0x7f060014; public static final int activity_vertical_margin=0x7f060015; public static final int avatar_size=0x7f060003; public static final int bar_length=0x7f060021; public static final int bar_pointer_halo_radius=0x7f060023; public static final int bar_pointer_radius=0x7f060022; /** Standart dimens for the bars */ public static final int bar_thickness=0x7f060020; public static final int bs_grid_bottom_padding=0x7f06000c; public static final int bs_grid_left_padding=0x7f060009; public static final int bs_grid_right_padding=0x7f06000b; public static final int bs_grid_top_padding=0x7f06000a; public static final int btn_txt_size=0x7f06000f; /** Inset shadow for RoundRectDrawableWithShadow. It is used to avoid gaps between the card and the shadow. */ public static final int cardview_compat_inset_shadow=0x7f060019; /** Elevation value to use for CardViews. Pre-L, it is equal to shadow size. */ public static final int cardview_default_elevation=0x7f060018; /** Default radius for CardView corners. */ public static final int cardview_default_radius=0x7f060017; public static final int color_center_halo_radius=0x7f06001c; public static final int color_center_radius=0x7f06001d; public static final int color_pointer_halo_radius=0x7f06001e; public static final int color_pointer_radius=0x7f06001f; public static final int color_wheel_radius=0x7f06001a; public static final int color_wheel_thickness=0x7f06001b; public static final int fab_icon_size=0x7f060005; public static final int fab_margin=0x7f060016; public static final int fab_shadow_offset=0x7f060006; public static final int fab_shadow_radius=0x7f060007; public static final int fab_size_normal=0x7f060004; public static final int fab_stroke_width=0x7f060008; public static final int gf_title_bar_height=0x7f060002; public static final int input_txt_size=0x7f060013; public static final int item_txt_size=0x7f060012; public static final int line_1px=0x7f06000e; /** 身体变形 */ public static final int max_dist=0x7f060000; public static final int msg_txt_size=0x7f060011; public static final int ratingbar_height=0x7f06002c; public static final int round_corner=0x7f06000d; public static final int title_txt_size=0x7f060010; public static final int txt_size_12=0x7f060024; public static final int txt_size_13=0x7f060025; public static final int txt_size_14=0x7f060026; public static final int txt_size_15=0x7f060027; public static final int txt_size_16=0x7f060028; public static final int txt_size_17=0x7f060029; public static final int txt_size_18=0x7f06002a; public static final int txt_size_20=0x7f06002b; public static final int warp_line=0x7f060001; } public static final class drawable { public static final int a1map=0x7f020000; public static final int albums_img=0x7f020001; public static final int arrow_icon=0x7f020002; public static final int bg_gf_crop_texture=0x7f020003; public static final int bg_ios_roundcorner=0x7f020004; public static final int bg_ios_roundcorner_all_bottom_gray=0x7f020005; public static final int bg_ios_roundcorner_all_top_gray=0x7f020006; public static final int bg_ios_roundcorner_bottom=0x7f020007; public static final int bg_ios_roundcorner_gray=0x7f020008; public static final int bg_ios_roundcorner_left_bottom_gray=0x7f020009; public static final int bg_ios_roundcorner_progress=0x7f02000a; public static final int bg_ios_roundcorner_right_bottom_gray=0x7f02000b; public static final int bg_ios_roundcorner_top=0x7f02000c; public static final int bg_toast=0x7f02000d; public static final int bg_touch_highlight_white=0x7f02000e; public static final int blackboard256=0x7f02000f; public static final int blue_bg=0x7f020010; public static final int bs_ic_clear=0x7f020011; public static final int bs_ic_clear_light=0x7f020012; public static final int bs_ic_more=0x7f020013; public static final int bs_ic_more_light=0x7f020014; public static final int bs_list_dark_selector=0x7f020015; public static final int bs_list_selector=0x7f020016; public static final int btn_bg_highlight_white=0x7f020017; public static final int btn_blue=0x7f020018; public static final int btn_view_back=0x7f020019; public static final int btn_view_ok=0x7f02001a; public static final int c1map=0x7f02001b; public static final int comment=0x7f02001c; public static final int common_dialog_bg=0x7f02001d; public static final int crayon=0x7f02001e; public static final int crop_button=0x7f02001f; public static final int default_image=0x7f020020; public static final int del_icon=0x7f020021; public static final int delete=0x7f020022; public static final int edit_icon=0x7f020023; public static final int edittext_nomal=0x7f020024; public static final int eraser=0x7f020025; public static final int et_cursor=0x7f020026; public static final int flower=0x7f020027; public static final int frame_around1=0x7f020028; public static final int frame_around1_bottom=0x7f020029; public static final int frame_around1_left=0x7f02002a; public static final int frame_around1_left_bottom=0x7f02002b; public static final int frame_around1_left_top=0x7f02002c; public static final int frame_around1_right=0x7f02002d; public static final int frame_around1_right_bottom=0x7f02002e; public static final int frame_around1_right_top=0x7f02002f; public static final int frame_around1_top=0x7f020030; public static final int frame_around2=0x7f020031; public static final int frame_around2_bottom=0x7f020032; public static final int frame_around2_left=0x7f020033; public static final int frame_around2_left_bottom=0x7f020034; public static final int frame_around2_left_top=0x7f020035; public static final int frame_around2_right=0x7f020036; public static final int frame_around2_right_bottom=0x7f020037; public static final int frame_around2_right_top=0x7f020038; public static final int frame_around2_top=0x7f020039; public static final int frame_big1=0x7f02003a; public static final int frame_small1=0x7f02003b; public static final int gf_ic_preview=0x7f02003c; public static final int girl1=0x7f02003d; public static final int girl2=0x7f02003e; public static final int gouda=0x7f02003f; public static final int guaishushu=0x7f020040; public static final int h2map=0x7f020041; public static final int h4map=0x7f020042; public static final int haoxingzuop=0x7f020043; public static final int hi0=0x7f020044; public static final int hi3=0x7f020045; public static final int hi4=0x7f020046; public static final int ic_action_camera=0x7f020047; public static final int ic_action_crop=0x7f020048; public static final int ic_action_previous_item=0x7f020049; public static final int ic_action_repeat=0x7f02004a; public static final int ic_delete_photo=0x7f02004b; public static final int ic_folder_check=0x7f02004c; public static final int ic_gf_back=0x7f02004d; public static final int ic_gf_camera=0x7f02004e; public static final int ic_gf_clear=0x7f02004f; public static final int ic_gf_crop=0x7f020050; public static final int ic_gf_crop_tile=0x7f020051; public static final int ic_gf_default_photo=0x7f020052; public static final int ic_gf_done=0x7f020053; public static final int ic_gf_preview=0x7f020054; public static final int ic_gf_rotate=0x7f020055; public static final int ic_gf_triangle_arrow=0x7f020056; public static final int ic_launcher=0x7f020057; public static final int ic_ratingbar=0x7f020058; public static final int icon_auto=0x7f020059; public static final int loading_large=0x7f02005a; public static final int loading_small=0x7f02005b; public static final int login_btn=0x7f02005c; public static final int logo=0x7f02005d; public static final int louguang=0x7f02005e; public static final int main_bg=0x7f02005f; public static final int make_album_img=0x7f020060; public static final int marker=0x7f020061; public static final int marker01=0x7f020062; public static final int marker1=0x7f020063; public static final int my_reward_account_tip_icon=0x7f020064; public static final int my_reward_icon=0x7f020065; public static final int paint=0x7f020066; public static final int pale_blue_bg=0x7f020067; public static final int photo_checkbox_bg=0x7f020068; public static final int photo_checkbox_bg2=0x7f020069; public static final int photo_list_dir_icon=0x7f02006a; public static final int photo_selected_bg=0x7f02006b; public static final int photo_selected_bg2=0x7f02006c; public static final int photo_unselected_bg=0x7f02006d; public static final int photo_unselected_bg2=0x7f02006e; public static final int progressstyleshape=0x7f02006f; public static final int ptr_rotate_arrow=0x7f020070; public static final int reward_img=0x7f020071; public static final int riguang=0x7f020072; public static final int river=0x7f020073; public static final int rotate=0x7f020074; public static final int selector_btn_press_all=0x7f020075; public static final int selector_btn_press_all_bottom=0x7f020076; public static final int selector_btn_press_all_top=0x7f020077; public static final int selector_btn_press_left_bottom=0x7f020078; public static final int selector_btn_press_no_corner=0x7f020079; public static final int selector_btn_press_right_bottom=0x7f02007a; public static final int setting_img=0x7f02007b; public static final int share_icon=0x7f02007c; public static final int slt_as_ios7_cancel_bt=0x7f02007d; public static final int slt_as_ios7_other_bt_bottom=0x7f02007e; public static final int slt_as_ios7_other_bt_middle=0x7f02007f; public static final int slt_as_ios7_other_bt_single=0x7f020080; public static final int slt_as_ios7_other_bt_top=0x7f020081; public static final int song2map=0x7f020082; public static final int stamp0star=0x7f020083; public static final int stamp1star=0x7f020084; public static final int stamp2star=0x7f020085; public static final int stamp3star=0x7f020086; public static final int sucai10=0x7f020087; public static final int sucai12=0x7f020088; public static final int sucai16=0x7f020089; public static final int sucai18=0x7f02008a; public static final int sucai24=0x7f02008b; public static final int sucai25=0x7f02008c; public static final int toast_bg=0x7f02008d; public static final int toast_fail_bg=0x7f02008e; public static final int toast_fail_icon=0x7f02008f; public static final int toast_success_icon=0x7f020090; public static final int toast_successs_bg=0x7f020091; public static final int top_more=0x7f020092; public static final int wanhuaile=0x7f020093; public static final int watermark_chunvzuo=0x7f020094; public static final int xiangsi=0x7f020095; public static final int xingzuokong=0x7f020096; public static final int xinnian=0x7f020097; public static final int youhua=0x7f020098; public static final int zaoan=0x7f020099; public static final int zui=0x7f02009a; public static final int zuile=0x7f02009b; public static final int zuo=0x7f02009c; } public static final class id { public static final int BallBeat=0x7f0a0013; public static final int BallClipRotate=0x7f0a0014; public static final int BallClipRotateMultiple=0x7f0a0015; public static final int BallClipRotatePulse=0x7f0a0016; public static final int BallGridBeat=0x7f0a0017; public static final int BallGridPulse=0x7f0a0018; public static final int BallPulse=0x7f0a0019; public static final int BallPulseRise=0x7f0a001a; public static final int BallPulseSync=0x7f0a001b; public static final int BallRotate=0x7f0a001c; public static final int BallScale=0x7f0a001d; public static final int BallScaleMultiple=0x7f0a001e; public static final int BallScaleRipple=0x7f0a001f; public static final int BallScaleRippleMultiple=0x7f0a0020; public static final int BallSpinFadeLoader=0x7f0a0021; public static final int BallTrianglePath=0x7f0a0022; public static final int BallZigZag=0x7f0a0023; public static final int BallZigZagDeflect=0x7f0a0024; public static final int CropOverlayView=0x7f0a00af; public static final int CubeTransition=0x7f0a0025; public static final int ImageView_image=0x7f0a00ae; public static final int LineScale=0x7f0a0026; public static final int LineScaleParty=0x7f0a0027; public static final int LineScalePulseOut=0x7f0a0028; public static final int LineScalePulseOutRapid=0x7f0a0029; public static final int LineSpinFadeLoader=0x7f0a002a; public static final int Pacman=0x7f0a002b; public static final int SemiCircleSpin=0x7f0a002c; public static final int SquareSpin=0x7f0a002d; public static final int TriangleSkewSpin=0x7f0a002e; public static final int action_16_9=0x7f0a0159; public static final int action_1_1=0x7f0a0156; public static final int action_3_2=0x7f0a0157; public static final int action_4_3=0x7f0a0158; public static final int action_addtv=0x7f0a0150; public static final int action_addwm=0x7f0a014d; public static final int action_base=0x7f0a0165; public static final int action_clean_cache=0x7f0a0162; public static final int action_color=0x7f0a015f; public static final int action_crop=0x7f0a014c; public static final int action_draw=0x7f0a014a; public static final int action_enchance=0x7f0a014e; public static final int action_eraser=0x7f0a0161; public static final int action_filter=0x7f0a0147; public static final int action_flower=0x7f0a0164; public static final int action_frame=0x7f0a0149; public static final int action_freedom=0x7f0a0155; public static final int action_function=0x7f0a0163; public static final int action_ground_glass=0x7f0a0166; public static final int action_left_right=0x7f0a015b; public static final int action_mosaic=0x7f0a014b; public static final int action_paint_one=0x7f0a015c; public static final int action_paint_two=0x7f0a015d; public static final int action_pic=0x7f0a0160; public static final int action_rotate=0x7f0a014f; public static final int action_size=0x7f0a015e; public static final int action_up_down=0x7f0a015a; public static final int action_wrap=0x7f0a0148; public static final int adapter_item_tag_key=0x7f0a0001; public static final int addPictureFromCamera=0x7f0a0046; public static final int addPictureFromPhoto=0x7f0a0045; public static final int addpic=0x7f0a006f; public static final int addtext=0x7f0a006e; public static final int albums_build_tv=0x7f0a0119; public static final int albums_img_content=0x7f0a0031; public static final int albums_img_iv=0x7f0a0033; public static final int albums_reward_tv=0x7f0a011a; public static final int av_loading_indicator=0x7f0a0128; public static final int body=0x7f0a013b; public static final int bottom_linear=0x7f0a0043; public static final int bottom_sheet_gridview=0x7f0a007f; public static final int bottom_sheet_title=0x7f0a0006; public static final int bottom_sheet_title_image=0x7f0a0005; public static final int brightness=0x7f0a0103; public static final int bs_list_image=0x7f0a0003; public static final int bs_list_title=0x7f0a0004; public static final int bs_main=0x7f0a007e; public static final int bs_more=0x7f0a0002; public static final int btn=0x7f0a00ea; public static final int btn_1=0x7f0a00ba; public static final int btn_1_vertical=0x7f0a00c0; public static final int btn_2=0x7f0a00bc; public static final int btn_2_vertical=0x7f0a00c2; public static final int btn_3=0x7f0a00be; public static final int btn_3_vertical=0x7f0a00c4; public static final int btn_bottom=0x7f0a00c6; public static final int btn_cancel=0x7f0a00f5; public static final int btn_ok=0x7f0a00f6; public static final int btn_open_gallery=0x7f0a00ab; public static final int btn_photo_folder_info=0x7f0a0054; public static final int btn_setting_check_version=0x7f0a004e; public static final int btn_setting_feed_back=0x7f0a004c; public static final int btn_setting_head=0x7f0a004a; public static final int btn_setting_nick_name=0x7f0a004b; public static final int btn_setting_remaind=0x7f0a004d; public static final int call=0x7f0a0153; public static final int cb_crop=0x7f0a009d; public static final int cb_crop_replace_source=0x7f0a009f; public static final int cb_crop_square=0x7f0a00a4; public static final int cb_edit=0x7f0a009b; public static final int cb_no_animation=0x7f0a00aa; public static final int cb_open_force_crop=0x7f0a00a6; public static final int cb_open_force_crop_edit=0x7f0a00a7; public static final int cb_preview=0x7f0a00a9; public static final int cb_rotate=0x7f0a009e; public static final int cb_rotate_replace_source=0x7f0a00a0; public static final int cb_show_camera=0x7f0a00a8; public static final int center=0x7f0a000a; public static final int centerCrop=0x7f0a000b; public static final int centerInside=0x7f0a000c; public static final int chunvzuo=0x7f0a0071; public static final int click=0x7f0a002f; public static final int color=0x7f0a006c; public static final int common_top_bar=0x7f0a0067; public static final int contrast=0x7f0a0104; public static final int cropmageView=0x7f0a00ad; public static final int drawLayout=0x7f0a00f9; public static final int drawView=0x7f0a00fa; public static final int empty_state_view=0x7f0a00dd; public static final int enhancePicture=0x7f0a0101; public static final int et_1=0x7f0a00b6; public static final int et_2=0x7f0a00b7; public static final int et_crop_height=0x7f0a00a3; public static final int et_crop_width=0x7f0a00a2; public static final int et_feed_back=0x7f0a004f; public static final int et_max_size=0x7f0a009a; public static final int et_setting_nick_name=0x7f0a0057; public static final int fab_crop=0x7f0a00cf; public static final int fab_label=0x7f0a0000; public static final int fab_ok=0x7f0a00de; public static final int face_linear=0x7f0a0068; public static final int faceby=0x7f0a006a; public static final int facebygf=0x7f0a006b; public static final int family=0x7f0a006d; public static final int fanTestLeftRight=0x7f0a0123; public static final int fanTestUpDown=0x7f0a0122; public static final int filterBlackWhite=0x7f0a0111; public static final int filterBrown=0x7f0a0113; public static final int filterComics=0x7f0a0110; public static final int filterGray=0x7f0a010c; public static final int filterLOMO=0x7f0a010e; public static final int filterMosatic=0x7f0a010d; public static final int filterNegative=0x7f0a0112; public static final int filterNiHong=0x7f0a0117; public static final int filterNostalgic=0x7f0a010f; public static final int filterOverExposure=0x7f0a0115; public static final int filterSketch=0x7f0a0118; public static final int filterSketchPencil=0x7f0a0114; public static final int filterSoftness=0x7f0a0116; public static final int filterWhite=0x7f0a010b; public static final int filter_test=0x7f0a00c8; public static final int filtersList=0x7f0a0070; public static final int filtersSV=0x7f0a0107; public static final int fingerprint_recognition_tb=0x7f0a0059; public static final int fitCenter=0x7f0a000d; public static final int fitEnd=0x7f0a000e; public static final int fitStart=0x7f0a000f; public static final int fitXY=0x7f0a0010; public static final int fl_check=0x7f0a00e7; public static final int fl_empty_view=0x7f0a00fb; public static final int focusCrop=0x7f0a0011; public static final int guaishushu=0x7f0a0074; public static final int gv_photo_list=0x7f0a0052; public static final int haoxingzuo=0x7f0a0075; public static final int header=0x7f0a0084; public static final int headerlayout=0x7f0a0083; public static final int help=0x7f0a0154; public static final int ic_game_icon=0x7f0a005a; public static final int iv_arrow=0x7f0a0055; public static final int iv_back=0x7f0a0087; public static final int iv_check=0x7f0a00e8; public static final int iv_clear=0x7f0a00d7; public static final int iv_cover=0x7f0a00e2; public static final int iv_crop=0x7f0a0129; public static final int iv_crop_photo=0x7f0a00ce; public static final int iv_delete=0x7f0a00e1; public static final int iv_folder_arrow=0x7f0a00d6; public static final int iv_folder_check=0x7f0a00e5; public static final int iv_fresco_source_photo=0x7f0a00cd; public static final int iv_icon=0x7f0a00e9; public static final int iv_loading=0x7f0a0126; public static final int iv_photo=0x7f0a0065; public static final int iv_preview=0x7f0a00d8; public static final int iv_rotate=0x7f0a012a; public static final int iv_source_photo=0x7f0a00cc; public static final int iv_take_photo=0x7f0a00d9; public static final int iv_thumb=0x7f0a00e6; public static final int jiuyaozuo=0x7f0a007c; public static final int layout_draw=0x7f0a00f8; public static final int layout_enhance=0x7f0a00fe; public static final int layout_filter=0x7f0a0105; public static final int layout_mosaic=0x7f0a011b; public static final int layout_revolve=0x7f0a011d; public static final int layout_warp=0x7f0a0124; public static final int line=0x7f0a00b8; public static final int line_btn2=0x7f0a00bb; public static final int line_btn2_vertical=0x7f0a00c1; public static final int line_btn3=0x7f0a00bd; public static final int line_btn3_vertical=0x7f0a00c3; public static final int ll_container=0x7f0a00c7; public static final int ll_container_horizontal=0x7f0a00b9; public static final int ll_container_vertical=0x7f0a00bf; public static final int ll_crop_size=0x7f0a00a1; public static final int ll_edit=0x7f0a009c; public static final int ll_folder_panel=0x7f0a00df; public static final int ll_force_crop=0x7f0a00a5; public static final int ll_gallery=0x7f0a00d0; public static final int ll_max_size=0x7f0a0099; public static final int ll_title=0x7f0a00d4; public static final int login_btn=0x7f0a0036; public static final int lv=0x7f0a00c5; public static final int lv_folder_list=0x7f0a00e0; public static final int lv_gallery=0x7f0a00d1; public static final int lv_games=0x7f0a00cb; public static final int lv_photo=0x7f0a00ac; public static final int mRlQQ=0x7f0a00f1; public static final int mRlQzone=0x7f0a00f3; public static final int mRlWechat=0x7f0a00eb; public static final int mRlWeibo=0x7f0a00ef; public static final int mRlWeixinCircle=0x7f0a00ed; public static final int main=0x7f0a0066; public static final int mainLayout=0x7f0a0042; public static final int make_album_img_iv=0x7f0a0032; public static final int make_photos=0x7f0a00dc; public static final int menu_bottom=0x7f0a011f; public static final int message=0x7f0a013c; public static final int moren=0x7f0a0069; public static final int mosaic=0x7f0a011c; public static final int none=0x7f0a0012; public static final int off=0x7f0a0007; public static final int on=0x7f0a0008; public static final int onTouch=0x7f0a0009; public static final int opacitybar=0x7f0a0140; public static final int pb_loading=0x7f0a00fc; public static final int pbar=0x7f0a00c9; public static final int photoRes=0x7f0a012d; public static final int photoResList=0x7f0a012c; public static final int photoRes_one=0x7f0a012e; public static final int photoRes_three=0x7f0a0130; public static final int photoRes_two=0x7f0a012f; public static final int photo_content_lay=0x7f0a0051; public static final int photo_frame=0x7f0a012b; public static final int picker=0x7f0a013e; public static final int picture=0x7f0a0106; public static final int pictureRl=0x7f0a00ff; public static final int pictureShow=0x7f0a0044; public static final int picture_revole=0x7f0a011e; public static final int pop_layout=0x7f0a013d; public static final int ptr_classic_header_rotate_view=0x7f0a00b3; public static final int ptr_classic_header_rotate_view_header_last_update=0x7f0a00b2; public static final int ptr_classic_header_rotate_view_header_text=0x7f0a00b0; public static final int ptr_classic_header_rotate_view_header_title=0x7f0a00b1; public static final int ptr_classic_header_rotate_view_progressbar=0x7f0a00b4; public static final int qiugouda=0x7f0a0073; public static final int rb_fresco=0x7f0a0094; public static final int rb_glide=0x7f0a0092; public static final int rb_muti_select=0x7f0a0098; public static final int rb_picasso=0x7f0a0093; public static final int rb_single_select=0x7f0a0097; public static final int rb_theme_custom=0x7f0a008b; public static final int rb_theme_cyan=0x7f0a008c; public static final int rb_theme_dark=0x7f0a0090; public static final int rb_theme_default=0x7f0a008a; public static final int rb_theme_green=0x7f0a008e; public static final int rb_theme_orange=0x7f0a008d; public static final int rb_theme_teal=0x7f0a008f; public static final int rb_uil=0x7f0a0091; public static final int rb_xutils=0x7f0a0096; public static final int rb_xutils3=0x7f0a0095; public static final int refresh_layout=0x7f0a00ca; public static final int regulator=0x7f0a0108; public static final int revoleTest=0x7f0a0120; public static final int reward_img_iv=0x7f0a0034; public static final int saturation=0x7f0a0102; public static final int saturationbar=0x7f0a0141; public static final int scroll=0x7f0a0030; public static final int selected_photos=0x7f0a00db; public static final int setting_img_iv=0x7f0a0035; public static final int share=0x7f0a0151; public static final int share_qq=0x7f0a00f2; public static final int share_qzone=0x7f0a00f4; public static final int share_weibo=0x7f0a00f0; public static final int share_wx=0x7f0a00ec; public static final int share_wx_timeline=0x7f0a00ee; public static final int shenhuifu=0x7f0a0072; public static final int statu_bar=0x7f0a0085; public static final int submit=0x7f0a0143; public static final int svbar=0x7f0a013f; public static final int tb_remaind_recieve_message=0x7f0a0058; public static final int testBtn=0x7f0a0047; public static final int title_bar_lay=0x7f0a0050; public static final int title_right=0x7f0a0089; public static final int titlebar=0x7f0a0086; public static final int titlebar_lay=0x7f0a00d2; public static final int toast_content=0x7f0a0146; public static final int toast_icon=0x7f0a0144; public static final int toast_title=0x7f0a0145; public static final int tone_sub_menu=0x7f0a0100; public static final int toolbar=0x7f0a0041; public static final int top_part=0x7f0a0037; public static final int tv_account_name=<KEY>; public static final int tv_accumulate_recieve_rewards=0x7f0a003b; public static final int tv_accumulate_withdraws=0x7f0a003a; public static final int tv_accumulate_withdraws_all=0x7f0a003d; public static final int tv_accumulate_withdraws_record=0x7f0a003c; public static final int tv_arrow=0x7f0a0056; public static final int tv_balance=0x7f0a0038; public static final int tv_balance_tip=0x7f0a0039; public static final int tv_bk=0x7f0a0133; public static final int tv_bottom=0x7f0a0082; public static final int tv_check_account=0x7f0a003e; public static final int tv_choose_count=0x7f0a00da; public static final int tv_del=0x7f0a0062; public static final int tv_edit=0x7f0a0063; public static final int tv_empty_message=0x7f0a00fd; public static final int tv_empty_view=0x7f0a0053; public static final int tv_fill_in=0x7f0a0040; public static final int tv_folder_name=0x7f0a00e3; public static final int tv_game_comment_number=0x7f0a0060; public static final int tv_game_fans=0x7f0a005d; public static final int tv_game_name=0x7f0a005c; public static final int tv_game_player_number=0x7f0a005f; public static final int tv_game_socre=0x7f0a005e; public static final int tv_indicator=0x7f0a0088; public static final int tv_jq=0x7f0a0136; public static final int tv_lj=0x7f0a0131; public static final int tv_loading_msg=0x7f0a0127; public static final int tv_msg=0x7f0a00b5; public static final int tv_msk=0x7f0a0135; public static final int tv_photo_count=0x7f0a00e4; public static final int tv_reward_record=0x7f0a0061; public static final int tv_rtbx=0x7f0a0132; public static final int tv_share=0x7f0a0064; public static final int tv_sub_title=0x7f0a00d5; public static final int tv_time=0x7f0a005b; public static final int tv_title=0x7f0a0080; public static final int tv_tjsy=0x7f0a0137; public static final int tv_tjwz=0x7f0a013a; public static final int tv_txzq=0x7f0a0138; public static final int tv_ty=0x7f0a0134; public static final int tv_xz=0x7f0a0139; public static final int txt_view_top_bar_title=0x7f0a00f7; public static final int unTest=0x7f0a0121; public static final int upload=0x7f0a0152; public static final int user_head_img=0x7f0a0048; public static final int user_name_tv=0x7f0a0049; public static final int valuebar=0x7f0a0142; public static final int verticalSeekBar=0x7f0a0109; public static final int verticalSeekBarProgressText=0x7f0a010a; public static final int view_line_bottom=0x7f0a0081; public static final int vp_pager=0x7f0a00d3; public static final int wanhuaile=0x7f0a0076; public static final int warp_image=0x7f0a0125; public static final int xiangsi=0x7f0a0077; public static final int xingzuokong=0x7f0a0078; public static final int xinnian=0x7f0a0079; public static final int zaoan=0x7f0a007a; public static final int zui=0x7f0a007d; public static final int zuile=0x7f0a007b; } public static final class integer { public static final int bs_grid_colum=0x7f0b0001; public static final int bs_initial_grid_row=0x7f0b0002; public static final int bs_initial_list_row=0x7f0b0003; public static final int no_limit=0x7f0b0000; } public static final class layout { public static final int activity_albums_img=0x7f040000; public static final int activity_main=0x7f040001; public static final int activity_main_layout=0x7f040002; public static final int activity_my_reward=0x7f040003; public static final int activity_photo_test=0x7f040004; public static final int activity_setting=0x7f040005; public static final int activity_setting_feed_back=0x7f040006; public static final int activity_setting_head=0x7f040007; public static final int activity_setting_nick_name=0x7f040008; public static final int activity_setting_remaind=0x7f040009; public static final int adapter_list_item=0x7f04000a; public static final int adapter_photo_list_item=0x7f04000b; public static final int addtext=0x7f04000c; public static final int addwatermark=0x7f04000d; public static final int bottom_sheet_dialog=0x7f04000e; public static final int bottomsheet_lv=0x7f04000f; public static final int bs_grid_entry=0x7f040010; public static final int bs_header=0x7f040011; public static final int bs_list_divider=0x7f040012; public static final int bs_list_entry=0x7f040013; public static final int comm_line=0x7f040014; public static final int comm_line_deep=0x7f040015; public static final int comm_line_vertical=0x7f040016; public static final int comm_title_bar=0x7f040017; public static final int comm_view_divider=0x7f040018; public static final int content_main=0x7f040019; public static final int crop_image=0x7f04001a; public static final int crop_image_view=0x7f04001b; public static final int cube_ptr_classic_default_header=0x7f04001c; public static final int cube_ptr_simple_loading=0x7f04001d; public static final int dialog_ios_alert=0x7f04001e; public static final int dialog_ios_alert_bottom=0x7f04001f; public static final int dialog_ios_alert_vertical=0x7f040020; public static final int dialog_ios_center_item=0x7f040021; public static final int filter_test=0x7f040022; public static final int fragment_srl_listview=0x7f040023; public static final int gf_activity_photo_edit=0x7f040024; public static final int gf_activity_photo_preview=0x7f040025; public static final int gf_activity_photo_select=0x7f040026; public static final int gf_adapter_edit_list=0x7f040027; public static final int gf_adapter_folder_list_item=0x7f040028; public static final int gf_adapter_fresco_preview_viewpgaer_item=0x7f040029; public static final int gf_adapter_photo_list_item=0x7f04002a; public static final int gf_adapter_preview_viewpgaer_item=0x7f04002b; public static final int item_bottomsheet_gv=0x7f04002c; public static final int item_bottomsheet_lv=0x7f04002d; public static final int item_btn_bottomalert=0x7f04002e; public static final int layout_bottom_share=0x7f04002f; public static final int layout_common_top_bar=0x7f040030; public static final int layout_draw=0x7f040031; public static final int layout_empty_view=0x7f040032; public static final int layout_enhance=0x7f040033; public static final int layout_filter=0x7f040034; public static final int layout_loadmorestyle_head=0x7f040035; public static final int layout_mosaic=0x7f040036; public static final int layout_revolve=0x7f040037; public static final int layout_warp=0x7f040038; public static final int loading=0x7f040039; public static final int loading_view_final_footer_default=0x7f04003a; public static final int loading_view_final_footer_style=0x7f04003b; public static final int loading_view_final_swipe_refresh_layout_attrs=0x7f04003c; public static final int photo_edit_title_bar=0x7f04003d; public static final int photo_frame=0x7f04003e; public static final int pop_photo_edit=0x7f04003f; public static final int popwindow_list=0x7f040040; public static final int progressview_wrapconent=0x7f040041; public static final int select_color=0x7f040042; public static final int toast_common_layout=0x7f040043; } public static final class menu { public static final int base_toolbar_menu=0x7f0d0000; public static final int list=0x7f0d0001; public static final int menu_crop=0x7f0d0002; public static final int menu_draw=0x7f0d0003; public static final int menu_main=0x7f0d0004; public static final int menu_mosaic=0x7f0d0005; public static final int noicon=0x7f0d0006; } public static final class mipmap { public static final int actionsheet_bg_ios6=0x7f030000; public static final int actionsheet_bottom_normal=0x7f030001; public static final int actionsheet_bottom_pressed=0x7f030002; public static final int actionsheet_cancel_bt_bg=0x7f030003; public static final int actionsheet_middle_normal=0x7f030004; public static final int actionsheet_middle_pressed=0x7f030005; public static final int actionsheet_other_bt_bg=0x7f030006; public static final int actionsheet_single_normal=0x7f030007; public static final int actionsheet_single_pressed=0x7f030008; public static final int actionsheet_top_normal=0x7f030009; public static final int actionsheet_top_pressed=0x7f03000a; public static final int banner01=0x7f03000b; public static final int banner02=0x7f03000c; public static final int banner03=0x7f03000d; public static final int banner04=0x7f03000e; public static final int ic_action_camera=0x7f03000f; public static final int ic_action_crop=0x7f030010; public static final int ic_action_previous_item=0x7f030011; public static final int ic_action_repeat=0x7f030012; public static final int ic_avatar=0x7f030013; public static final int ic_launcher=0x7f030014; public static final int ic_ratingbar_selector=0x7f030015; public static final int ic_ratingbar_unselector=0x7f030016; public static final int share_moment=0x7f030017; public static final int share_qq=0x7f030018; public static final int share_qzone=0x7f030019; public static final int share_wechat=0x7f03001a; public static final int share_weibo=0x7f03001b; } public static final class string { public static final int action_settings=0x7f070029; public static final int all_photo=0x7f070010; public static final int app_name=0x7f070000; public static final int aspectRatioX=0x7f07005b; public static final int aspectRatioXHeader=0x7f07005c; public static final int aspectRatioY=0x7f07005d; public static final int aspectRatioYHeader=0x7f07005e; public static final int bs_more=0x7f070026; public static final int crop=0x7f070060; public static final int crop_fail=0x7f070017; public static final int crop_suc=0x7f070016; public static final int croppedImageDesc=0x7f070062; public static final int cube_ptr_hours_ago=0x7f070009; public static final int cube_ptr_last_update=0x7f070006; public static final int cube_ptr_minutes_ago=0x7f070008; public static final int cube_ptr_pull_down=0x7f070001; public static final int cube_ptr_pull_down_to_refresh=0x7f070002; public static final int cube_ptr_refresh_complete=0x7f070005; public static final int cube_ptr_refreshing=0x7f070004; public static final int cube_ptr_release_to_refresh=0x7f070003; public static final int cube_ptr_seconds_ago=0x7f070007; public static final int device_type=0x7f070027; public static final int edit_letoff_photo_format=0x7f070020; public static final int empty_sdcard=0x7f07001b; public static final int fixedAspectRatio=0x7f07005a; public static final int folder_photo_size=0x7f070013; public static final int gallery=0x7f07000f; public static final int loading_view_click_loading_more=0x7f07000a; public static final int loading_view_loading=0x7f07000c; public static final int loading_view_net_error=0x7f07000d; public static final int loading_view_no_more=0x7f07000b; public static final int maxsize_zero_tip=0x7f070025; public static final int no_photo=0x7f070018; public static final int open_gallery_fail=0x7f07001c; public static final int permissions_denied_tips=0x7f070024; public static final int permissions_tips_gallery=0x7f070023; public static final int photo_crop=0x7f070015; public static final int photo_edit=0x7f070014; public static final int photo_list_empty=0x7f070021; public static final int photo_selected=0x7f070012; public static final int please_reopen_gf=0x7f07001f; public static final int preview=0x7f070022; public static final int rotate=0x7f070061; public static final int saving=0x7f07001e; public static final int select_max_tips=0x7f07001a; public static final int selected=0x7f070011; public static final int showGuidelines=0x7f07005f; public static final int str_account_name=0x7f070045; public static final int str_accumulate_recieve_rewards=0x7f07003f; public static final int str_accumulate_withdraws=0x7f07003e; public static final int str_accumulate_withdraws_all=0x7f070041; public static final int str_accumulate_withdraws_record=0x7f070040; public static final int str_albums_imgs_build_label=0x7f07002b; public static final int str_albums_imgs_build_value=0x7f07002c; public static final int str_albums_imgs_reward_label=0x7f07002d; public static final int str_albums_imgs_reward_value=0x7f07002e; public static final int str_back=0x7f07000e; public static final int str_balance=0x7f07003c; public static final int str_balance_tip=0x7f07003d; public static final int str_check_account=0x7f070044; public static final int str_del=0x7f070035; public static final int str_edit=0x7f070036; public static final int str_fill_in=0x7f070038; /** 制作相册 */ public static final int str_less_than_three_photos=0x7f07002a; public static final int str_my_account=0x7f070042; public static final int str_my_account_tip=0x7f070043; /** 我的相册 */ public static final int str_my_albums=0x7f07002f; public static final int str_my_albums_fans=0x7f070030; public static final int str_my_albums_rewards=0x7f070032; public static final int str_my_albums_rewards_money=0x7f070033; public static final int str_my_albums_rewards_record=0x7f070034; public static final int str_my_albums_scans=0x7f070031; /** 我的打赏 */ public static final int str_my_rewards=0x7f07003b; public static final int str_remaind_recieve_message=0x7f070055; public static final int str_remaind_recieve_message_tip=0x7f070056; public static final int str_remaind_shack=0x7f070058; public static final int str_remaind_voice=0x7f070057; public static final int str_remaind_voice_shack_tip=0x7f070059; /** 设置 */ public static final int str_setting=0x7f070046; public static final int str_setting_check_version=0x7f07004c; public static final int str_setting_feed_back=0x7f07004a; public static final int str_setting_feed_back_tip=0x7f070053; public static final int str_setting_head=0x7f070048; public static final int str_setting_head_tip=0x7f070047; public static final int str_setting_nick_name=0x7f070049; public static final int str_setting_nick_name_finish=0x7f07004f; public static final int str_setting_nick_name_hint=0x7f070050; public static final int str_setting_reminded=0x7f07004b; public static final int str_share=0x7f070037; public static final int str_title_comfirm_del=0x7f070039; public static final int str_title_comfirm_del_albums=0x7f07003a; public static final int str_title_select_photos=0x7f07004d; public static final int str_title_setting_feed_back=0x7f070051; public static final int str_title_setting_feed_back_send=0x7f070052; public static final int str_title_setting_nick_name=0x7f07004e; public static final int str_title_setting_remaind=0x7f070054; public static final int take_photo_fail=0x7f07001d; public static final int vista_share_title=0x7f070028; public static final int waiting=0x7f070019; } public static final class style { /** All customizations that are NOT specific to a particular API-level can go here. */ public static final int ActionBarTheme=0x7f080005; public static final int ActionSheetStyleiOS6=0x7f080002; public static final int ActionSheetStyleiOS7=0x7f080003; /** Base application theme, dependent on API level. This theme is replaced by AppBaseTheme from res/values-vXX/styles.xml on newer devices. Theme customizations available in newer API levels can go in res/values-vXX/styles.xml, while customizations related to backward-compatibility can go here. Base application theme for API 11+. This theme completely replaces AppBaseTheme from res/values/styles.xml on API 11+ devices. API 11 theme customizations can go here. Base application theme for API 14+. This theme completely replaces AppBaseTheme from BOTH res/values/styles.xml and res/values-v11/styles.xml on API 14+ devices. API 14 theme customizations can go here. Base application theme, dependent on API level. This theme is replaced by AppBaseTheme from res/values-vXX/styles.xml on newer devices. Theme customizations available in newer API levels can go in res/values-vXX/styles.xml, while customizations related to backward-compatibility can go here. Base application theme for API 11+. This theme completely replaces AppBaseTheme from res/values/styles.xml on API 11+ devices. API 11 theme customizations can go here. Base application theme for API 14+. This theme completely replaces AppBaseTheme from BOTH res/values/styles.xml and res/values-v11/styles.xml on API 14+ devices. API 14 theme customizations can go here. Base application theme, dependent on API level. This theme is replaced by AppBaseTheme from res/values-vXX/styles.xml on newer devices. Theme customizations available in newer API levels can go in res/values-vXX/styles.xml, while customizations related to backward-compatibility can go here. Base application theme for API 11+. This theme completely replaces AppBaseTheme from res/values/styles.xml on API 11+ devices. API 11 theme customizations can go here. Base application theme for API 14+. This theme completely replaces AppBaseTheme from BOTH res/values/styles.xml and res/values-v11/styles.xml on API 14+ devices. API 14 theme customizations can go here. Base application theme, dependent on API level. This theme is replaced by AppBaseTheme from res/values-vXX/styles.xml on newer devices. Theme customizations available in newer API levels can go in res/values-vXX/styles.xml, while customizations related to backward-compatibility can go here. Base application theme for API 11+. This theme completely replaces AppBaseTheme from res/values/styles.xml on API 11+ devices. API 11 theme customizations can go here. Base application theme for API 14+. This theme completely replaces AppBaseTheme from BOTH res/values/styles.xml and res/values-v11/styles.xml on API 14+ devices. API 14 theme customizations can go here. Base application theme, dependent on API level. This theme is replaced by AppBaseTheme from res/values-vXX/styles.xml on newer devices. */ public static final int AppBaseTheme=0x7f080000; /** Application theme. All customizations that are NOT specific to a particular API-level can go here. Application theme. All customizations that are NOT specific to a particular API-level can go here. Application theme. All customizations that are NOT specific to a particular API-level can go here. Application theme. All customizations that are NOT specific to a particular API-level can go here. Application theme. All customizations that are NOT specific to a particular API-level can go here. */ public static final int AppTheme=0x7f080001; /** bottomDialog */ public static final int BottomDialog=0x7f08000a; public static final int BottomDialog_AnimationStyle=0x7f08000b; /** BottomSheet */ public static final int BottomSheet=0x7f080010; public static final int BottomSheet_Animation=0x7f080024; public static final int BottomSheet_Dialog=0x7f080011; public static final int BottomSheet_Dialog_Dark=0x7f080012; public static final int BottomSheet_Grid=0x7f080022; public static final int BottomSheet_GridItem=0x7f080023; public static final int BottomSheet_GridItemImage=0x7f080020; public static final int BottomSheet_GridItemTitle=0x7f080021; public static final int BottomSheet_Icon=0x7f080019; public static final int BottomSheet_List=0x7f08001a; public static final int BottomSheet_List_Dark=0x7f08001b; public static final int BottomSheet_ListDivider=0x7f08001f; public static final int BottomSheet_ListItem=0x7f08001c; public static final int BottomSheet_ListItemImage=0x7f08001d; public static final int BottomSheet_ListItemTitle=0x7f08001e; public static final int BottomSheet_Title=0x7f080018; public static final int BottomSheet_TopDivider=0x7f080025; /** cardview */ public static final int CardView=0x7f080007; public static final int CardView_Dark=0x7f080009; public static final int CardView_Light=0x7f080008; /** All customizations that are NOT specific to a particular API-level can go here. */ public static final int FullBleedTheme=0x7f080004; /** RatingBarStyle */ public static final int RatingBarStyle=0x7f080006; /** Robo Theme. */ public static final int RoboTheme=0x7f08002f; public static final int Text=0x7f080013; public static final int Text_Headline=0x7f080014; public static final int Text_Hint=0x7f080016; public static final int Text_Subhead=0x7f080017; public static final int Text_Title=0x7f080015; public static final int Widget_GifMoviewView=0x7f08000f; public static final int bottom_menu=0x7f080029; public static final int dialog_center=0x7f08000d; /** 图片编辑 */ public static final int image_view_preview=0x7f080026; public static final int mystyle=0x7f08000c; public static final int notitle=0x7f08000e; public static final int sub_menu=0x7f08002e; public static final int tabbar_2btn_4word_style=0x7f08002d; public static final int tabbar_2btn_style=0x7f08002a; public static final int tabbar_3btn_style=0x7f08002c; public static final int tabbar_btn_style=0x7f08002b; public static final int top_bar_bg=0x7f080027; public static final int top_bar_title_txt=0x7f080028; } public static final class styleable { /** Attributes that can be used with a AVLoadingIndicatorView. <p>Includes the following attributes:</p> <table> <colgroup align="left" /> <colgroup align="left" /> <tr><th>Attribute</th><th>Description</th></tr> <tr><td><code>{@link #AVLoadingIndicatorView_indicator com.bop.zz:indicator}</code></td><td></td></tr> <tr><td><code>{@link #AVLoadingIndicatorView_indicator_color com.bop.zz:indicator_color}</code></td><td></td></tr> </table> @see #AVLoadingIndicatorView_indicator @see #AVLoadingIndicatorView_indicator_color */ public static final int[] AVLoadingIndicatorView = { 0x7f010031, 0x7f010032 }; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#indicator} attribute's value can be found in the {@link #AVLoadingIndicatorView} array. <p>Must be one or more (separated by '|') of the following constant values.</p> <table> <colgroup align="left" /> <colgroup align="left" /> <colgroup align="left" /> <tr><th>Constant</th><th>Value</th><th>Description</th></tr> <tr><td><code>BallPulse</code></td><td>0</td><td></td></tr> <tr><td><code>BallGridPulse</code></td><td>1</td><td></td></tr> <tr><td><code>BallClipRotate</code></td><td>2</td><td></td></tr> <tr><td><code>BallClipRotatePulse</code></td><td>3</td><td></td></tr> <tr><td><code>SquareSpin</code></td><td>4</td><td></td></tr> <tr><td><code>BallClipRotateMultiple</code></td><td>5</td><td></td></tr> <tr><td><code>BallPulseRise</code></td><td>6</td><td></td></tr> <tr><td><code>BallRotate</code></td><td>7</td><td></td></tr> <tr><td><code>CubeTransition</code></td><td>8</td><td></td></tr> <tr><td><code>BallZigZag</code></td><td>9</td><td></td></tr> <tr><td><code>BallZigZagDeflect</code></td><td>10</td><td></td></tr> <tr><td><code>BallTrianglePath</code></td><td>11</td><td></td></tr> <tr><td><code>BallScale</code></td><td>12</td><td></td></tr> <tr><td><code>LineScale</code></td><td>13</td><td></td></tr> <tr><td><code>LineScaleParty</code></td><td>14</td><td></td></tr> <tr><td><code>BallScaleMultiple</code></td><td>15</td><td></td></tr> <tr><td><code>BallPulseSync</code></td><td>16</td><td></td></tr> <tr><td><code>BallBeat</code></td><td>17</td><td></td></tr> <tr><td><code>LineScalePulseOut</code></td><td>18</td><td></td></tr> <tr><td><code>LineScalePulseOutRapid</code></td><td>19</td><td></td></tr> <tr><td><code>BallScaleRipple</code></td><td>20</td><td></td></tr> <tr><td><code>BallScaleRippleMultiple</code></td><td>21</td><td></td></tr> <tr><td><code>BallSpinFadeLoader</code></td><td>22</td><td></td></tr> <tr><td><code>LineSpinFadeLoader</code></td><td>23</td><td></td></tr> <tr><td><code>TriangleSkewSpin</code></td><td>24</td><td></td></tr> <tr><td><code>Pacman</code></td><td>25</td><td></td></tr> <tr><td><code>BallGridBeat</code></td><td>26</td><td></td></tr> <tr><td><code>SemiCircleSpin</code></td><td>27</td><td></td></tr> </table> @attr name com.bop.zz:indicator */ public static final int AVLoadingIndicatorView_indicator = 0; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#indicator_color} attribute's value can be found in the {@link #AVLoadingIndicatorView} array. <p>Must be a color value, in the form of "<code>#<i>rgb</i></code>", "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or "<code>#<i>aarrggbb</i></code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. @attr name com.bop.zz:indicator_color */ public static final int AVLoadingIndicatorView_indicator_color = 1; /** Attributes that can be used with a ActionSheet. <p>Includes the following attributes:</p> <table> <colgroup align="left" /> <colgroup align="left" /> <tr><th>Attribute</th><th>Description</th></tr> <tr><td><code>{@link #ActionSheet_actionSheetBackground com.bop.zz:actionSheetBackground}</code></td><td></td></tr> <tr><td><code>{@link #ActionSheet_actionSheetPadding com.bop.zz:actionSheetPadding}</code></td><td></td></tr> <tr><td><code>{@link #ActionSheet_actionSheetTextSize com.bop.zz:actionSheetTextSize}</code></td><td></td></tr> <tr><td><code>{@link #ActionSheet_cancelButtonBackground com.bop.zz:cancelButtonBackground}</code></td><td></td></tr> <tr><td><code>{@link #ActionSheet_cancelButtonMarginTop com.bop.zz:cancelButtonMarginTop}</code></td><td></td></tr> <tr><td><code>{@link #ActionSheet_cancelButtonTextColor com.bop.zz:cancelButtonTextColor}</code></td><td></td></tr> <tr><td><code>{@link #ActionSheet_otherButtonBottomBackground com.bop.zz:otherButtonBottomBackground}</code></td><td></td></tr> <tr><td><code>{@link #ActionSheet_otherButtonMiddleBackground com.bop.zz:otherButtonMiddleBackground}</code></td><td></td></tr> <tr><td><code>{@link #ActionSheet_otherButtonSingleBackground com.bop.zz:otherButtonSingleBackground}</code></td><td></td></tr> <tr><td><code>{@link #ActionSheet_otherButtonSpacing com.bop.zz:otherButtonSpacing}</code></td><td></td></tr> <tr><td><code>{@link #ActionSheet_otherButtonTextColor com.bop.zz:otherButtonTextColor}</code></td><td></td></tr> <tr><td><code>{@link #ActionSheet_otherButtonTopBackground com.bop.zz:otherButtonTopBackground}</code></td><td></td></tr> </table> @see #ActionSheet_actionSheetBackground @see #ActionSheet_actionSheetPadding @see #ActionSheet_actionSheetTextSize @see #ActionSheet_cancelButtonBackground @see #ActionSheet_cancelButtonMarginTop @see #ActionSheet_cancelButtonTextColor @see #ActionSheet_otherButtonBottomBackground @see #ActionSheet_otherButtonMiddleBackground @see #ActionSheet_otherButtonSingleBackground @see #ActionSheet_otherButtonSpacing @see #ActionSheet_otherButtonTextColor @see #ActionSheet_otherButtonTopBackground */ public static final int[] ActionSheet = { 0x7f010020, 0x7f010021, 0x7f010022, 0x7f010023, 0x7f010024, 0x7f010025, 0x7f010026, 0x7f010027, 0x7f010028, 0x7f010029, 0x7f01002a, 0x7f01002b }; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#actionSheetBackground} attribute's value can be found in the {@link #ActionSheet} array. <p>May be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or "<code>#<i>aarrggbb</i></code>". @attr name com.bop.zz:actionSheetBackground */ public static final int ActionSheet_actionSheetBackground = 0; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#actionSheetPadding} attribute's value can be found in the {@link #ActionSheet} array. <p>May be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". <p>May be a dimension value, which is a floating point number appended with a unit such as "<code>14.5sp</code>". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), mm (millimeters). @attr name com.bop.zz:actionSheetPadding */ public static final int ActionSheet_actionSheetPadding = 8; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#actionSheetTextSize} attribute's value can be found in the {@link #ActionSheet} array. <p>May be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". <p>May be a dimension value, which is a floating point number appended with a unit such as "<code>14.5sp</code>". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), mm (millimeters). @attr name com.bop.zz:actionSheetTextSize */ public static final int ActionSheet_actionSheetTextSize = 11; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#cancelButtonBackground} attribute's value can be found in the {@link #ActionSheet} array. <p>May be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or "<code>#<i>aarrggbb</i></code>". @attr name com.bop.zz:cancelButtonBackground */ public static final int ActionSheet_cancelButtonBackground = 1; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#cancelButtonMarginTop} attribute's value can be found in the {@link #ActionSheet} array. <p>May be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". <p>May be a dimension value, which is a floating point number appended with a unit such as "<code>14.5sp</code>". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), mm (millimeters). @attr name com.bop.zz:cancelButtonMarginTop */ public static final int ActionSheet_cancelButtonMarginTop = 10; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#cancelButtonTextColor} attribute's value can be found in the {@link #ActionSheet} array. <p>May be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or "<code>#<i>aarrggbb</i></code>". @attr name com.bop.zz:cancelButtonTextColor */ public static final int ActionSheet_cancelButtonTextColor = 6; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#otherButtonBottomBackground} attribute's value can be found in the {@link #ActionSheet} array. <p>May be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or "<code>#<i>aarrggbb</i></code>". @attr name com.bop.zz:otherButtonBottomBackground */ public static final int ActionSheet_otherButtonBottomBackground = 4; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#otherButtonMiddleBackground} attribute's value can be found in the {@link #ActionSheet} array. <p>May be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or "<code>#<i>aarrggbb</i></code>". @attr name com.bop.zz:otherButtonMiddleBackground */ public static final int ActionSheet_otherButtonMiddleBackground = 3; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#otherButtonSingleBackground} attribute's value can be found in the {@link #ActionSheet} array. <p>May be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or "<code>#<i>aarrggbb</i></code>". @attr name com.bop.zz:otherButtonSingleBackground */ public static final int ActionSheet_otherButtonSingleBackground = 5; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#otherButtonSpacing} attribute's value can be found in the {@link #ActionSheet} array. <p>May be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". <p>May be a dimension value, which is a floating point number appended with a unit such as "<code>14.5sp</code>". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), mm (millimeters). @attr name com.bop.zz:otherButtonSpacing */ public static final int ActionSheet_otherButtonSpacing = 9; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#otherButtonTextColor} attribute's value can be found in the {@link #ActionSheet} array. <p>May be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or "<code>#<i>aarrggbb</i></code>". @attr name com.bop.zz:otherButtonTextColor */ public static final int ActionSheet_otherButtonTextColor = 7; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#otherButtonTopBackground} attribute's value can be found in the {@link #ActionSheet} array. <p>May be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or "<code>#<i>aarrggbb</i></code>". @attr name com.bop.zz:otherButtonTopBackground */ public static final int ActionSheet_otherButtonTopBackground = 2; /** Attributes that can be used with a ActionSheets. <p>Includes the following attributes:</p> <table> <colgroup align="left" /> <colgroup align="left" /> <tr><th>Attribute</th><th>Description</th></tr> <tr><td><code>{@link #ActionSheets_actionSheetStyle com.bop.zz:actionSheetStyle}</code></td><td></td></tr> </table> @see #ActionSheets_actionSheetStyle */ public static final int[] ActionSheets = { 0x7f01001f }; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#actionSheetStyle} attribute's value can be found in the {@link #ActionSheets} array. <p>Must be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". @attr name com.bop.zz:actionSheetStyle */ public static final int ActionSheets_actionSheetStyle = 0; /** Attributes that can be used with a BottomSheet. <p>Includes the following attributes:</p> <table> <colgroup align="left" /> <colgroup align="left" /> <tr><th>Attribute</th><th>Description</th></tr> <tr><td><code>{@link #BottomSheet_bs_bottomSheetStyle com.bop.zz:bs_bottomSheetStyle}</code></td><td></td></tr> <tr><td><code>{@link #BottomSheet_bs_closeDrawable com.bop.zz:bs_closeDrawable}</code></td><td></td></tr> <tr><td><code>{@link #BottomSheet_bs_collapseListIcons com.bop.zz:bs_collapseListIcons}</code></td><td></td></tr> <tr><td><code>{@link #BottomSheet_bs_dialogBackground com.bop.zz:bs_dialogBackground}</code></td><td></td></tr> <tr><td><code>{@link #BottomSheet_bs_dividerColor com.bop.zz:bs_dividerColor}</code></td><td></td></tr> <tr><td><code>{@link #BottomSheet_bs_gridItemLayout com.bop.zz:bs_gridItemLayout}</code></td><td></td></tr> <tr><td><code>{@link #BottomSheet_bs_gridItemTitleTextAppearance com.bop.zz:bs_gridItemTitleTextAppearance}</code></td><td></td></tr> <tr><td><code>{@link #BottomSheet_bs_headerLayout com.bop.zz:bs_headerLayout}</code></td><td></td></tr> <tr><td><code>{@link #BottomSheet_bs_listItemLayout com.bop.zz:bs_listItemLayout}</code></td><td></td></tr> <tr><td><code>{@link #BottomSheet_bs_listItemTitleTextAppearance com.bop.zz:bs_listItemTitleTextAppearance}</code></td><td></td></tr> <tr><td><code>{@link #BottomSheet_bs_listStyle com.bop.zz:bs_listStyle}</code></td><td></td></tr> <tr><td><code>{@link #BottomSheet_bs_moreDrawable com.bop.zz:bs_moreDrawable}</code></td><td></td></tr> <tr><td><code>{@link #BottomSheet_bs_moreText com.bop.zz:bs_moreText}</code></td><td></td></tr> <tr><td><code>{@link #BottomSheet_bs_numColumns com.bop.zz:bs_numColumns}</code></td><td></td></tr> <tr><td><code>{@link #BottomSheet_bs_titleTextAppearance com.bop.zz:bs_titleTextAppearance}</code></td><td></td></tr> </table> @see #BottomSheet_bs_bottomSheetStyle @see #BottomSheet_bs_closeDrawable @see #BottomSheet_bs_collapseListIcons @see #BottomSheet_bs_dialogBackground @see #BottomSheet_bs_dividerColor @see #BottomSheet_bs_gridItemLayout @see #BottomSheet_bs_gridItemTitleTextAppearance @see #BottomSheet_bs_headerLayout @see #BottomSheet_bs_listItemLayout @see #BottomSheet_bs_listItemTitleTextAppearance @see #BottomSheet_bs_listStyle @see #BottomSheet_bs_moreDrawable @see #BottomSheet_bs_moreText @see #BottomSheet_bs_numColumns @see #BottomSheet_bs_titleTextAppearance */ public static final int[] BottomSheet = { 0x7f010043, 0x7f010044, 0x7f010045, 0x7f010046, 0x7f010047, 0x7f010048, 0x7f010049, 0x7f01004a, 0x7f01004b, 0x7f01004c, 0x7f01004d, 0x7f01004e, 0x7f01004f, 0x7f010050, 0x7f010051 }; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#bs_bottomSheetStyle} attribute's value can be found in the {@link #BottomSheet} array. <p>Must be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". @attr name com.bop.zz:bs_bottomSheetStyle */ public static final int BottomSheet_bs_bottomSheetStyle = 0; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#bs_closeDrawable} attribute's value can be found in the {@link #BottomSheet} array. <p>Must be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". @attr name com.bop.zz:bs_closeDrawable */ public static final int BottomSheet_bs_closeDrawable = 10; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#bs_collapseListIcons} attribute's value can be found in the {@link #BottomSheet} array. <p>Must be a boolean value, either "<code>true</code>" or "<code>false</code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. @attr name com.bop.zz:bs_collapseListIcons */ public static final int BottomSheet_bs_collapseListIcons = 11; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#bs_dialogBackground} attribute's value can be found in the {@link #BottomSheet} array. <p>May be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or "<code>#<i>aarrggbb</i></code>". @attr name com.bop.zz:bs_dialogBackground */ public static final int BottomSheet_bs_dialogBackground = 1; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#bs_dividerColor} attribute's value can be found in the {@link #BottomSheet} array. <p>May be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or "<code>#<i>aarrggbb</i></code>". @attr name com.bop.zz:bs_dividerColor */ public static final int BottomSheet_bs_dividerColor = 3; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#bs_gridItemLayout} attribute's value can be found in the {@link #BottomSheet} array. <p>Must be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". @attr name com.bop.zz:bs_gridItemLayout */ public static final int BottomSheet_bs_gridItemLayout = 13; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#bs_gridItemTitleTextAppearance} attribute's value can be found in the {@link #BottomSheet} array. <p>Must be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". @attr name com.bop.zz:bs_gridItemTitleTextAppearance */ public static final int BottomSheet_bs_gridItemTitleTextAppearance = 7; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#bs_headerLayout} attribute's value can be found in the {@link #BottomSheet} array. <p>Must be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". @attr name com.bop.zz:bs_headerLayout */ public static final int BottomSheet_bs_headerLayout = 14; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#bs_listItemLayout} attribute's value can be found in the {@link #BottomSheet} array. <p>Must be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". @attr name com.bop.zz:bs_listItemLayout */ public static final int BottomSheet_bs_listItemLayout = 12; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#bs_listItemTitleTextAppearance} attribute's value can be found in the {@link #BottomSheet} array. <p>Must be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". @attr name com.bop.zz:bs_listItemTitleTextAppearance */ public static final int BottomSheet_bs_listItemTitleTextAppearance = 6; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#bs_listStyle} attribute's value can be found in the {@link #BottomSheet} array. <p>Must be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". @attr name com.bop.zz:bs_listStyle */ public static final int BottomSheet_bs_listStyle = 2; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#bs_moreDrawable} attribute's value can be found in the {@link #BottomSheet} array. <p>Must be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". @attr name com.bop.zz:bs_moreDrawable */ public static final int BottomSheet_bs_moreDrawable = 8; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#bs_moreText} attribute's value can be found in the {@link #BottomSheet} array. <p>Must be a string value, using '\\;' to escape characters such as '\\n' or '\\uxxxx' for a unicode character. <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. @attr name com.bop.zz:bs_moreText */ public static final int BottomSheet_bs_moreText = 9; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#bs_numColumns} attribute's value can be found in the {@link #BottomSheet} array. <p>Must be an integer value, such as "<code>100</code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. @attr name com.bop.zz:bs_numColumns */ public static final int BottomSheet_bs_numColumns = 4; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#bs_titleTextAppearance} attribute's value can be found in the {@link #BottomSheet} array. <p>Must be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". @attr name com.bop.zz:bs_titleTextAppearance */ public static final int BottomSheet_bs_titleTextAppearance = 5; /** Attributes that can be used with a CardView. <p>Includes the following attributes:</p> <table> <colgroup align="left" /> <colgroup align="left" /> <tr><th>Attribute</th><th>Description</th></tr> <tr><td><code>{@link #CardView_cardBackgroundColor com.bop.zz:cardBackgroundColor}</code></td><td> Background color for CardView.</td></tr> <tr><td><code>{@link #CardView_cardCornerRadius com.bop.zz:cardCornerRadius}</code></td><td> Corner radius for CardView.</td></tr> <tr><td><code>{@link #CardView_cardElevation com.bop.zz:cardElevation}</code></td><td> Elevation for CardView.</td></tr> <tr><td><code>{@link #CardView_cardMaxElevation com.bop.zz:cardMaxElevation}</code></td><td> Maximum Elevation for CardView.</td></tr> <tr><td><code>{@link #CardView_cardPreventCornerOverlap com.bop.zz:cardPreventCornerOverlap}</code></td><td> Add padding to CardView on v20 and before to prevent intersections between the Card content and rounded corners.</td></tr> <tr><td><code>{@link #CardView_cardUseCompatPadding com.bop.zz:cardUseCompatPadding}</code></td><td> Add padding in API v21+ as well to have the same measurements with previous versions.</td></tr> <tr><td><code>{@link #CardView_contentPadding com.bop.zz:contentPadding}</code></td><td> 下面是卡片边界距离内部的距离 Inner padding between the edges of the Card and children of the CardView.</td></tr> <tr><td><code>{@link #CardView_contentPaddingBottom com.bop.zz:contentPaddingBottom}</code></td><td> Inner padding between the bottom edge of the Card and children of the CardView.</td></tr> <tr><td><code>{@link #CardView_contentPaddingLeft com.bop.zz:contentPaddingLeft}</code></td><td> Inner padding between the left edge of the Card and children of the CardView.</td></tr> <tr><td><code>{@link #CardView_contentPaddingRight com.bop.zz:contentPaddingRight}</code></td><td> Inner padding between the right edge of the Card and children of the CardView.</td></tr> <tr><td><code>{@link #CardView_contentPaddingTop com.bop.zz:contentPaddingTop}</code></td><td> Inner padding between the top edge of the Card and children of the CardView.</td></tr> </table> @see #CardView_cardBackgroundColor @see #CardView_cardCornerRadius @see #CardView_cardElevation @see #CardView_cardMaxElevation @see #CardView_cardPreventCornerOverlap @see #CardView_cardUseCompatPadding @see #CardView_contentPadding @see #CardView_contentPaddingBottom @see #CardView_contentPaddingLeft @see #CardView_contentPaddingRight @see #CardView_contentPaddingTop */ public static final int[] CardView = { 0x7f010033, 0x7f010034, 0x7f010035, 0x7f010036, 0x7f010037, 0x7f010038, 0x7f010039, 0x7f01003a, 0x7f01003b, 0x7f01003c, 0x7f01003d }; /** <p> @attr description Background color for CardView. 背景色 <p>Must be a color value, in the form of "<code>#<i>rgb</i></code>", "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or "<code>#<i>aarrggbb</i></code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. <p>This is a private symbol. @attr name com.bop.zz:cardBackgroundColor */ public static final int CardView_cardBackgroundColor = 0; /** <p> @attr description Corner radius for CardView. 边缘弧度数 <p>Must be a dimension value, which is a floating point number appended with a unit such as "<code>14.5sp</code>". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), mm (millimeters). <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. <p>This is a private symbol. @attr name com.bop.zz:cardCornerRadius */ public static final int CardView_cardCornerRadius = 1; /** <p> @attr description Elevation for CardView. 高度 <p>Must be a dimension value, which is a floating point number appended with a unit such as "<code>14.5sp</code>". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), mm (millimeters). <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. <p>This is a private symbol. @attr name com.bop.zz:cardElevation */ public static final int CardView_cardElevation = 2; /** <p> @attr description Maximum Elevation for CardView. 最大高度 <p>Must be a dimension value, which is a floating point number appended with a unit such as "<code>14.5sp</code>". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), mm (millimeters). <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. <p>This is a private symbol. @attr name com.bop.zz:cardMaxElevation */ public static final int CardView_cardMaxElevation = 3; /** <p> @attr description Add padding to CardView on v20 and before to prevent intersections between the Card content and rounded corners. 在v20和之前的版本中添加内边距,这个属性是为了防止卡片内容和边角的重叠 <p>Must be a boolean value, either "<code>true</code>" or "<code>false</code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. <p>This is a private symbol. @attr name com.bop.zz:cardPreventCornerOverlap */ public static final int CardView_cardPreventCornerOverlap = 5; /** <p> @attr description Add padding in API v21+ as well to have the same measurements with previous versions. 设置内边距,v21+的版本和之前的版本仍旧具有一样的计算方式 <p>Must be a boolean value, either "<code>true</code>" or "<code>false</code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. <p>This is a private symbol. @attr name com.bop.zz:cardUseCompatPadding */ public static final int CardView_cardUseCompatPadding = 4; /** <p> @attr description 下面是卡片边界距离内部的距离 Inner padding between the edges of the Card and children of the CardView. <p>Must be a dimension value, which is a floating point number appended with a unit such as "<code>14.5sp</code>". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), mm (millimeters). <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. <p>This is a private symbol. @attr name com.bop.zz:contentPadding */ public static final int CardView_contentPadding = 6; /** <p> @attr description Inner padding between the bottom edge of the Card and children of the CardView. <p>Must be a dimension value, which is a floating point number appended with a unit such as "<code>14.5sp</code>". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), mm (millimeters). <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. <p>This is a private symbol. @attr name com.bop.zz:contentPaddingBottom */ public static final int CardView_contentPaddingBottom = 10; /** <p> @attr description Inner padding between the left edge of the Card and children of the CardView. <p>Must be a dimension value, which is a floating point number appended with a unit such as "<code>14.5sp</code>". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), mm (millimeters). <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. <p>This is a private symbol. @attr name com.bop.zz:contentPaddingLeft */ public static final int CardView_contentPaddingLeft = 7; /** <p> @attr description Inner padding between the right edge of the Card and children of the CardView. <p>Must be a dimension value, which is a floating point number appended with a unit such as "<code>14.5sp</code>". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), mm (millimeters). <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. <p>This is a private symbol. @attr name com.bop.zz:contentPaddingRight */ public static final int CardView_contentPaddingRight = 8; /** <p> @attr description Inner padding between the top edge of the Card and children of the CardView. <p>Must be a dimension value, which is a floating point number appended with a unit such as "<code>14.5sp</code>". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), mm (millimeters). <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. <p>This is a private symbol. @attr name com.bop.zz:contentPaddingTop */ public static final int CardView_contentPaddingTop = 9; /** 圆形ImageView属性 <p>Includes the following attributes:</p> <table> <colgroup align="left" /> <colgroup align="left" /> <tr><th>Attribute</th><th>Description</th></tr> <tr><td><code>{@link #CircleImageView_border_color com.bop.zz:border_color}</code></td><td></td></tr> <tr><td><code>{@link #CircleImageView_border_width com.bop.zz:border_width}</code></td><td></td></tr> </table> @see #CircleImageView_border_color @see #CircleImageView_border_width */ public static final int[] CircleImageView = { 0x7f010041, 0x7f010042 }; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#border_color} attribute's value can be found in the {@link #CircleImageView} array. <p>Must be a color value, in the form of "<code>#<i>rgb</i></code>", "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or "<code>#<i>aarrggbb</i></code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. @attr name com.bop.zz:border_color */ public static final int CircleImageView_border_color = 1; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#border_width} attribute's value can be found in the {@link #CircleImageView} array. <p>Must be a dimension value, which is a floating point number appended with a unit such as "<code>14.5sp</code>". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), mm (millimeters). <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. @attr name com.bop.zz:border_width */ public static final int CircleImageView_border_width = 0; /** Attributes that can be used with a ColorBars. <p>Includes the following attributes:</p> <table> <colgroup align="left" /> <colgroup align="left" /> <tr><th>Attribute</th><th>Description</th></tr> <tr><td><code>{@link #ColorBars_bar_length com.bop.zz:bar_length}</code></td><td></td></tr> <tr><td><code>{@link #ColorBars_bar_orientation_horizontal com.bop.zz:bar_orientation_horizontal}</code></td><td></td></tr> <tr><td><code>{@link #ColorBars_bar_pointer_halo_radius com.bop.zz:bar_pointer_halo_radius}</code></td><td></td></tr> <tr><td><code>{@link #ColorBars_bar_pointer_radius com.bop.zz:bar_pointer_radius}</code></td><td></td></tr> <tr><td><code>{@link #ColorBars_bar_thickness com.bop.zz:bar_thickness}</code></td><td></td></tr> </table> @see #ColorBars_bar_length @see #ColorBars_bar_orientation_horizontal @see #ColorBars_bar_pointer_halo_radius @see #ColorBars_bar_pointer_radius @see #ColorBars_bar_thickness */ public static final int[] ColorBars = { 0x7f01005f, 0x7f010060, 0x7f010061, 0x7f010062, 0x7f010063 }; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#bar_length} attribute's value can be found in the {@link #ColorBars} array. <p>Must be a dimension value, which is a floating point number appended with a unit such as "<code>14.5sp</code>". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), mm (millimeters). <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. @attr name com.bop.zz:bar_length */ public static final int ColorBars_bar_length = 1; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#bar_orientation_horizontal} attribute's value can be found in the {@link #ColorBars} array. <p>Must be a boolean value, either "<code>true</code>" or "<code>false</code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. @attr name com.bop.zz:bar_orientation_horizontal */ public static final int ColorBars_bar_orientation_horizontal = 4; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#bar_pointer_halo_radius} attribute's value can be found in the {@link #ColorBars} array. <p>Must be a dimension value, which is a floating point number appended with a unit such as "<code>14.5sp</code>". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), mm (millimeters). <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. @attr name com.bop.zz:bar_pointer_halo_radius */ public static final int ColorBars_bar_pointer_halo_radius = 3; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#bar_pointer_radius} attribute's value can be found in the {@link #ColorBars} array. <p>Must be a dimension value, which is a floating point number appended with a unit such as "<code>14.5sp</code>". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), mm (millimeters). <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. @attr name com.bop.zz:bar_pointer_radius */ public static final int ColorBars_bar_pointer_radius = 2; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#bar_thickness} attribute's value can be found in the {@link #ColorBars} array. <p>Must be a dimension value, which is a floating point number appended with a unit such as "<code>14.5sp</code>". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), mm (millimeters). <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. @attr name com.bop.zz:bar_thickness */ public static final int ColorBars_bar_thickness = 0; /** Attributes that can be used with a ColorPicker. <p>Includes the following attributes:</p> <table> <colgroup align="left" /> <colgroup align="left" /> <tr><th>Attribute</th><th>Description</th></tr> <tr><td><code>{@link #ColorPicker_color_center_halo_radius com.bop.zz:color_center_halo_radius}</code></td><td></td></tr> <tr><td><code>{@link #ColorPicker_color_center_radius com.bop.zz:color_center_radius}</code></td><td></td></tr> <tr><td><code>{@link #ColorPicker_color_pointer_halo_radius com.bop.zz:color_pointer_halo_radius}</code></td><td></td></tr> <tr><td><code>{@link #ColorPicker_color_pointer_radius com.bop.zz:color_pointer_radius}</code></td><td></td></tr> <tr><td><code>{@link #ColorPicker_color_wheel_radius com.bop.zz:color_wheel_radius}</code></td><td></td></tr> <tr><td><code>{@link #ColorPicker_color_wheel_thickness com.bop.zz:color_wheel_thickness}</code></td><td></td></tr> </table> @see #ColorPicker_color_center_halo_radius @see #ColorPicker_color_center_radius @see #ColorPicker_color_pointer_halo_radius @see #ColorPicker_color_pointer_radius @see #ColorPicker_color_wheel_radius @see #ColorPicker_color_wheel_thickness */ public static final int[] ColorPicker = { 0x7f010059, 0x7f01005a, 0x7f01005b, 0x7f01005c, 0x7f01005d, 0x7f01005e }; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#color_center_halo_radius} attribute's value can be found in the {@link #ColorPicker} array. <p>Must be a dimension value, which is a floating point number appended with a unit such as "<code>14.5sp</code>". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), mm (millimeters). <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. @attr name com.bop.zz:color_center_halo_radius */ public static final int ColorPicker_color_center_halo_radius = 3; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#color_center_radius} attribute's value can be found in the {@link #ColorPicker} array. <p>Must be a dimension value, which is a floating point number appended with a unit such as "<code>14.5sp</code>". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), mm (millimeters). <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. @attr name com.bop.zz:color_center_radius */ public static final int ColorPicker_color_center_radius = 2; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#color_pointer_halo_radius} attribute's value can be found in the {@link #ColorPicker} array. <p>Must be a dimension value, which is a floating point number appended with a unit such as "<code>14.5sp</code>". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), mm (millimeters). <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. @attr name com.bop.zz:color_pointer_halo_radius */ public static final int ColorPicker_color_pointer_halo_radius = 5; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#color_pointer_radius} attribute's value can be found in the {@link #ColorPicker} array. <p>Must be a dimension value, which is a floating point number appended with a unit such as "<code>14.5sp</code>". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), mm (millimeters). <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. @attr name com.bop.zz:color_pointer_radius */ public static final int ColorPicker_color_pointer_radius = 4; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#color_wheel_radius} attribute's value can be found in the {@link #ColorPicker} array. <p>Must be a dimension value, which is a floating point number appended with a unit such as "<code>14.5sp</code>". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), mm (millimeters). <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. @attr name com.bop.zz:color_wheel_radius */ public static final int ColorPicker_color_wheel_radius = 0; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#color_wheel_thickness} attribute's value can be found in the {@link #ColorPicker} array. <p>Must be a dimension value, which is a floating point number appended with a unit such as "<code>14.5sp</code>". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), mm (millimeters). <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. @attr name com.bop.zz:color_wheel_thickness */ public static final int ColorPicker_color_wheel_thickness = 1; /** Attributes that can be used with a CropImageView. <p>Includes the following attributes:</p> <table> <colgroup align="left" /> <colgroup align="left" /> <tr><th>Attribute</th><th>Description</th></tr> <tr><td><code>{@link #CropImageView_aspectRatioX com.bop.zz:aspectRatioX}</code></td><td></td></tr> <tr><td><code>{@link #CropImageView_aspectRatioY com.bop.zz:aspectRatioY}</code></td><td></td></tr> <tr><td><code>{@link #CropImageView_fixAspectRatio com.bop.zz:fixAspectRatio}</code></td><td></td></tr> <tr><td><code>{@link #CropImageView_guidelines com.bop.zz:guidelines}</code></td><td></td></tr> <tr><td><code>{@link #CropImageView_imageResource com.bop.zz:imageResource}</code></td><td></td></tr> </table> @see #CropImageView_aspectRatioX @see #CropImageView_aspectRatioY @see #CropImageView_fixAspectRatio @see #CropImageView_guidelines @see #CropImageView_imageResource */ public static final int[] CropImageView = { 0x7f010000, 0x7f010001, 0x7f010002, 0x7f010003, 0x7f010004 }; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#aspectRatioX} attribute's value can be found in the {@link #CropImageView} array. <p>Must be an integer value, such as "<code>100</code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. @attr name com.bop.zz:aspectRatioX */ public static final int CropImageView_aspectRatioX = 2; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#aspectRatioY} attribute's value can be found in the {@link #CropImageView} array. <p>Must be an integer value, such as "<code>100</code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. @attr name com.bop.zz:aspectRatioY */ public static final int CropImageView_aspectRatioY = 3; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#fixAspectRatio} attribute's value can be found in the {@link #CropImageView} array. <p>Must be a boolean value, either "<code>true</code>" or "<code>false</code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. @attr name com.bop.zz:fixAspectRatio */ public static final int CropImageView_fixAspectRatio = 1; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#guidelines} attribute's value can be found in the {@link #CropImageView} array. <p>Must be one of the following constant values.</p> <table> <colgroup align="left" /> <colgroup align="left" /> <colgroup align="left" /> <tr><th>Constant</th><th>Value</th><th>Description</th></tr> <tr><td><code>on</code></td><td>2</td><td></td></tr> <tr><td><code>onTouch</code></td><td>1</td><td></td></tr> <tr><td><code>off</code></td><td>0</td><td></td></tr> </table> @attr name com.bop.zz:guidelines */ public static final int CropImageView_guidelines = 0; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#imageResource} attribute's value can be found in the {@link #CropImageView} array. <p>Must be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". @attr name com.bop.zz:imageResource */ public static final int CropImageView_imageResource = 4; /** Attributes that can be used with a CustomTheme. <p>Includes the following attributes:</p> <table> <colgroup align="left" /> <colgroup align="left" /> <tr><th>Attribute</th><th>Description</th></tr> <tr><td><code>{@link #CustomTheme_gifMoviewViewStyle com.bop.zz:gifMoviewViewStyle}</code></td><td></td></tr> </table> @see #CustomTheme_gifMoviewViewStyle */ public static final int[] CustomTheme = { 0x7f010040 }; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#gifMoviewViewStyle} attribute's value can be found in the {@link #CustomTheme} array. <p>Must be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". @attr name com.bop.zz:gifMoviewViewStyle */ public static final int CustomTheme_gifMoviewViewStyle = 0; /** <attr name="colorTheme" format="reference|color"/> <attr name="colorThemeDark" format="reference|color"/> <p>Includes the following attributes:</p> <table> <colgroup align="left" /> <colgroup align="left" /> <tr><th>Attribute</th><th>Description</th></tr> <tr><td><code>{@link #GFFloatingActionButton_fabColorNormal com.bop.zz:fabColorNormal}</code></td><td></td></tr> <tr><td><code>{@link #GFFloatingActionButton_fabColorPressed com.bop.zz:fabColorPressed}</code></td><td></td></tr> <tr><td><code>{@link #GFFloatingActionButton_fabIcon com.bop.zz:fabIcon}</code></td><td></td></tr> <tr><td><code>{@link #GFFloatingActionButton_fabTitle com.bop.zz:fabTitle}</code></td><td></td></tr> </table> @see #GFFloatingActionButton_fabColorNormal @see #GFFloatingActionButton_fabColorPressed @see #GFFloatingActionButton_fabIcon @see #GFFloatingActionButton_fabTitle */ public static final int[] GFFloatingActionButton = { 0x7f01002c, 0x7f01002d, 0x7f01002e, 0x7f01002f }; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#fabColorNormal} attribute's value can be found in the {@link #GFFloatingActionButton} array. <p>Must be a color value, in the form of "<code>#<i>rgb</i></code>", "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or "<code>#<i>aarrggbb</i></code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. @attr name com.bop.zz:fabColorNormal */ public static final int GFFloatingActionButton_fabColorNormal = 1; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#fabColorPressed} attribute's value can be found in the {@link #GFFloatingActionButton} array. <p>Must be a color value, in the form of "<code>#<i>rgb</i></code>", "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or "<code>#<i>aarrggbb</i></code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. @attr name com.bop.zz:fabColorPressed */ public static final int GFFloatingActionButton_fabColorPressed = 0; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#fabIcon} attribute's value can be found in the {@link #GFFloatingActionButton} array. <p>Must be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". @attr name com.bop.zz:fabIcon */ public static final int GFFloatingActionButton_fabIcon = 2; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#fabTitle} attribute's value can be found in the {@link #GFFloatingActionButton} array. <p>Must be a string value, using '\\;' to escape characters such as '\\n' or '\\uxxxx' for a unicode character. <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. @attr name com.bop.zz:fabTitle */ public static final int GFFloatingActionButton_fabTitle = 3; /** Attributes that can be used with a GenericDraweeHierarchy. <p>Includes the following attributes:</p> <table> <colgroup align="left" /> <colgroup align="left" /> <tr><th>Attribute</th><th>Description</th></tr> <tr><td><code>{@link #GenericDraweeHierarchy_actualImageScaleType com.bop.zz:actualImageScaleType}</code></td><td></td></tr> <tr><td><code>{@link #GenericDraweeHierarchy_backgroundImage com.bop.zz:backgroundImage}</code></td><td></td></tr> <tr><td><code>{@link #GenericDraweeHierarchy_fadeDuration com.bop.zz:fadeDuration}</code></td><td></td></tr> <tr><td><code>{@link #GenericDraweeHierarchy_failureImage com.bop.zz:failureImage}</code></td><td></td></tr> <tr><td><code>{@link #GenericDraweeHierarchy_failureImageScaleType com.bop.zz:failureImageScaleType}</code></td><td></td></tr> <tr><td><code>{@link #GenericDraweeHierarchy_overlayImage com.bop.zz:overlayImage}</code></td><td></td></tr> <tr><td><code>{@link #GenericDraweeHierarchy_placeholderImage com.bop.zz:placeholderImage}</code></td><td></td></tr> <tr><td><code>{@link #GenericDraweeHierarchy_placeholderImageScaleType com.bop.zz:placeholderImageScaleType}</code></td><td></td></tr> <tr><td><code>{@link #GenericDraweeHierarchy_pressedStateOverlayImage com.bop.zz:pressedStateOverlayImage}</code></td><td></td></tr> <tr><td><code>{@link #GenericDraweeHierarchy_progressBarAutoRotateInterval com.bop.zz:progressBarAutoRotateInterval}</code></td><td></td></tr> <tr><td><code>{@link #GenericDraweeHierarchy_progressBarImage com.bop.zz:progressBarImage}</code></td><td></td></tr> <tr><td><code>{@link #GenericDraweeHierarchy_progressBarImageScaleType com.bop.zz:progressBarImageScaleType}</code></td><td></td></tr> <tr><td><code>{@link #GenericDraweeHierarchy_retryImage com.bop.zz:retryImage}</code></td><td></td></tr> <tr><td><code>{@link #GenericDraweeHierarchy_retryImageScaleType com.bop.zz:retryImageScaleType}</code></td><td></td></tr> <tr><td><code>{@link #GenericDraweeHierarchy_roundAsCircle com.bop.zz:roundAsCircle}</code></td><td></td></tr> <tr><td><code>{@link #GenericDraweeHierarchy_roundBottomLeft com.bop.zz:roundBottomLeft}</code></td><td></td></tr> <tr><td><code>{@link #GenericDraweeHierarchy_roundBottomRight com.bop.zz:roundBottomRight}</code></td><td></td></tr> <tr><td><code>{@link #GenericDraweeHierarchy_roundTopLeft com.bop.zz:roundTopLeft}</code></td><td></td></tr> <tr><td><code>{@link #GenericDraweeHierarchy_roundTopRight com.bop.zz:roundTopRight}</code></td><td></td></tr> <tr><td><code>{@link #GenericDraweeHierarchy_roundWithOverlayColor com.bop.zz:roundWithOverlayColor}</code></td><td></td></tr> <tr><td><code>{@link #GenericDraweeHierarchy_roundedCornerRadius com.bop.zz:roundedCornerRadius}</code></td><td></td></tr> <tr><td><code>{@link #GenericDraweeHierarchy_roundingBorderColor com.bop.zz:roundingBorderColor}</code></td><td></td></tr> <tr><td><code>{@link #GenericDraweeHierarchy_roundingBorderPadding com.bop.zz:roundingBorderPadding}</code></td><td></td></tr> <tr><td><code>{@link #GenericDraweeHierarchy_roundingBorderWidth com.bop.zz:roundingBorderWidth}</code></td><td></td></tr> <tr><td><code>{@link #GenericDraweeHierarchy_viewAspectRatio com.bop.zz:viewAspectRatio}</code></td><td></td></tr> </table> @see #GenericDraweeHierarchy_actualImageScaleType @see #GenericDraweeHierarchy_backgroundImage @see #GenericDraweeHierarchy_fadeDuration @see #GenericDraweeHierarchy_failureImage @see #GenericDraweeHierarchy_failureImageScaleType @see #GenericDraweeHierarchy_overlayImage @see #GenericDraweeHierarchy_placeholderImage @see #GenericDraweeHierarchy_placeholderImageScaleType @see #GenericDraweeHierarchy_pressedStateOverlayImage @see #GenericDraweeHierarchy_progressBarAutoRotateInterval @see #GenericDraweeHierarchy_progressBarImage @see #GenericDraweeHierarchy_progressBarImageScaleType @see #GenericDraweeHierarchy_retryImage @see #GenericDraweeHierarchy_retryImageScaleType @see #GenericDraweeHierarchy_roundAsCircle @see #GenericDraweeHierarchy_roundBottomLeft @see #GenericDraweeHierarchy_roundBottomRight @see #GenericDraweeHierarchy_roundTopLeft @see #GenericDraweeHierarchy_roundTopRight @see #GenericDraweeHierarchy_roundWithOverlayColor @see #GenericDraweeHierarchy_roundedCornerRadius @see #GenericDraweeHierarchy_roundingBorderColor @see #GenericDraweeHierarchy_roundingBorderPadding @see #GenericDraweeHierarchy_roundingBorderWidth @see #GenericDraweeHierarchy_viewAspectRatio */ public static final int[] GenericDraweeHierarchy = { 0x7f010005, 0x7f010006, 0x7f010007, 0x7f010008, 0x7f010009, 0x7f01000a, 0x7f01000b, 0x7f01000c, 0x7f01000d, 0x7f01000e, 0x7f01000f, 0x7f010010, 0x7f010011, 0x7f010012, 0x7f010013, 0x7f010014, 0x7f010015, 0x7f010016, 0x7f010017, 0x7f010018, 0x7f010019, 0x7f01001a, 0x7f01001b, 0x7f01001c, 0x7f01001d }; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#actualImageScaleType} attribute's value can be found in the {@link #GenericDraweeHierarchy} array. <p>Must be one of the following constant values.</p> <table> <colgroup align="left" /> <colgroup align="left" /> <colgroup align="left" /> <tr><th>Constant</th><th>Value</th><th>Description</th></tr> <tr><td><code>none</code></td><td>-1</td><td></td></tr> <tr><td><code>fitXY</code></td><td>0</td><td></td></tr> <tr><td><code>fitStart</code></td><td>1</td><td></td></tr> <tr><td><code>fitCenter</code></td><td>2</td><td></td></tr> <tr><td><code>fitEnd</code></td><td>3</td><td></td></tr> <tr><td><code>center</code></td><td>4</td><td></td></tr> <tr><td><code>centerInside</code></td><td>5</td><td></td></tr> <tr><td><code>centerCrop</code></td><td>6</td><td></td></tr> <tr><td><code>focusCrop</code></td><td>7</td><td></td></tr> </table> @attr name com.bop.zz:actualImageScaleType */ public static final int GenericDraweeHierarchy_actualImageScaleType = 11; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#backgroundImage} attribute's value can be found in the {@link #GenericDraweeHierarchy} array. <p>Must be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". @attr name com.bop.zz:backgroundImage */ public static final int GenericDraweeHierarchy_backgroundImage = 12; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#fadeDuration} attribute's value can be found in the {@link #GenericDraweeHierarchy} array. <p>Must be an integer value, such as "<code>100</code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. @attr name com.bop.zz:fadeDuration */ public static final int GenericDraweeHierarchy_fadeDuration = 0; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#failureImage} attribute's value can be found in the {@link #GenericDraweeHierarchy} array. <p>Must be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". @attr name com.bop.zz:failureImage */ public static final int GenericDraweeHierarchy_failureImage = 6; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#failureImageScaleType} attribute's value can be found in the {@link #GenericDraweeHierarchy} array. <p>Must be one of the following constant values.</p> <table> <colgroup align="left" /> <colgroup align="left" /> <colgroup align="left" /> <tr><th>Constant</th><th>Value</th><th>Description</th></tr> <tr><td><code>none</code></td><td>-1</td><td></td></tr> <tr><td><code>fitXY</code></td><td>0</td><td></td></tr> <tr><td><code>fitStart</code></td><td>1</td><td></td></tr> <tr><td><code>fitCenter</code></td><td>2</td><td></td></tr> <tr><td><code>fitEnd</code></td><td>3</td><td></td></tr> <tr><td><code>center</code></td><td>4</td><td></td></tr> <tr><td><code>centerInside</code></td><td>5</td><td></td></tr> <tr><td><code>centerCrop</code></td><td>6</td><td></td></tr> <tr><td><code>focusCrop</code></td><td>7</td><td></td></tr> </table> @attr name com.bop.zz:failureImageScaleType */ public static final int GenericDraweeHierarchy_failureImageScaleType = 7; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#overlayImage} attribute's value can be found in the {@link #GenericDraweeHierarchy} array. <p>Must be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". @attr name com.bop.zz:overlayImage */ public static final int GenericDraweeHierarchy_overlayImage = 13; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#placeholderImage} attribute's value can be found in the {@link #GenericDraweeHierarchy} array. <p>Must be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". @attr name com.bop.zz:placeholderImage */ public static final int GenericDraweeHierarchy_placeholderImage = 2; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#placeholderImageScaleType} attribute's value can be found in the {@link #GenericDraweeHierarchy} array. <p>Must be one of the following constant values.</p> <table> <colgroup align="left" /> <colgroup align="left" /> <colgroup align="left" /> <tr><th>Constant</th><th>Value</th><th>Description</th></tr> <tr><td><code>none</code></td><td>-1</td><td></td></tr> <tr><td><code>fitXY</code></td><td>0</td><td></td></tr> <tr><td><code>fitStart</code></td><td>1</td><td></td></tr> <tr><td><code>fitCenter</code></td><td>2</td><td></td></tr> <tr><td><code>fitEnd</code></td><td>3</td><td></td></tr> <tr><td><code>center</code></td><td>4</td><td></td></tr> <tr><td><code>centerInside</code></td><td>5</td><td></td></tr> <tr><td><code>centerCrop</code></td><td>6</td><td></td></tr> <tr><td><code>focusCrop</code></td><td>7</td><td></td></tr> </table> @attr name com.bop.zz:placeholderImageScaleType */ public static final int GenericDraweeHierarchy_placeholderImageScaleType = 3; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#pressedStateOverlayImage} attribute's value can be found in the {@link #GenericDraweeHierarchy} array. <p>Must be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". @attr name com.bop.zz:pressedStateOverlayImage */ public static final int GenericDraweeHierarchy_pressedStateOverlayImage = 14; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#progressBarAutoRotateInterval} attribute's value can be found in the {@link #GenericDraweeHierarchy} array. <p>Must be an integer value, such as "<code>100</code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. @attr name com.bop.zz:progressBarAutoRotateInterval */ public static final int GenericDraweeHierarchy_progressBarAutoRotateInterval = 10; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#progressBarImage} attribute's value can be found in the {@link #GenericDraweeHierarchy} array. <p>Must be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". @attr name com.bop.zz:progressBarImage */ public static final int GenericDraweeHierarchy_progressBarImage = 8; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#progressBarImageScaleType} attribute's value can be found in the {@link #GenericDraweeHierarchy} array. <p>Must be one of the following constant values.</p> <table> <colgroup align="left" /> <colgroup align="left" /> <colgroup align="left" /> <tr><th>Constant</th><th>Value</th><th>Description</th></tr> <tr><td><code>none</code></td><td>-1</td><td></td></tr> <tr><td><code>fitXY</code></td><td>0</td><td></td></tr> <tr><td><code>fitStart</code></td><td>1</td><td></td></tr> <tr><td><code>fitCenter</code></td><td>2</td><td></td></tr> <tr><td><code>fitEnd</code></td><td>3</td><td></td></tr> <tr><td><code>center</code></td><td>4</td><td></td></tr> <tr><td><code>centerInside</code></td><td>5</td><td></td></tr> <tr><td><code>centerCrop</code></td><td>6</td><td></td></tr> <tr><td><code>focusCrop</code></td><td>7</td><td></td></tr> </table> @attr name com.bop.zz:progressBarImageScaleType */ public static final int GenericDraweeHierarchy_progressBarImageScaleType = 9; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#retryImage} attribute's value can be found in the {@link #GenericDraweeHierarchy} array. <p>Must be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". @attr name com.bop.zz:retryImage */ public static final int GenericDraweeHierarchy_retryImage = 4; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#retryImageScaleType} attribute's value can be found in the {@link #GenericDraweeHierarchy} array. <p>Must be one of the following constant values.</p> <table> <colgroup align="left" /> <colgroup align="left" /> <colgroup align="left" /> <tr><th>Constant</th><th>Value</th><th>Description</th></tr> <tr><td><code>none</code></td><td>-1</td><td></td></tr> <tr><td><code>fitXY</code></td><td>0</td><td></td></tr> <tr><td><code>fitStart</code></td><td>1</td><td></td></tr> <tr><td><code>fitCenter</code></td><td>2</td><td></td></tr> <tr><td><code>fitEnd</code></td><td>3</td><td></td></tr> <tr><td><code>center</code></td><td>4</td><td></td></tr> <tr><td><code>centerInside</code></td><td>5</td><td></td></tr> <tr><td><code>centerCrop</code></td><td>6</td><td></td></tr> <tr><td><code>focusCrop</code></td><td>7</td><td></td></tr> </table> @attr name com.bop.zz:retryImageScaleType */ public static final int GenericDraweeHierarchy_retryImageScaleType = 5; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#roundAsCircle} attribute's value can be found in the {@link #GenericDraweeHierarchy} array. <p>Must be a boolean value, either "<code>true</code>" or "<code>false</code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. @attr name com.bop.zz:roundAsCircle */ public static final int GenericDraweeHierarchy_roundAsCircle = 15; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#roundBottomLeft} attribute's value can be found in the {@link #GenericDraweeHierarchy} array. <p>Must be a boolean value, either "<code>true</code>" or "<code>false</code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. @attr name com.bop.zz:roundBottomLeft */ public static final int GenericDraweeHierarchy_roundBottomLeft = 20; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#roundBottomRight} attribute's value can be found in the {@link #GenericDraweeHierarchy} array. <p>Must be a boolean value, either "<code>true</code>" or "<code>false</code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. @attr name com.bop.zz:roundBottomRight */ public static final int GenericDraweeHierarchy_roundBottomRight = 19; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#roundTopLeft} attribute's value can be found in the {@link #GenericDraweeHierarchy} array. <p>Must be a boolean value, either "<code>true</code>" or "<code>false</code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. @attr name com.bop.zz:roundTopLeft */ public static final int GenericDraweeHierarchy_roundTopLeft = 17; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#roundTopRight} attribute's value can be found in the {@link #GenericDraweeHierarchy} array. <p>Must be a boolean value, either "<code>true</code>" or "<code>false</code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. @attr name com.bop.zz:roundTopRight */ public static final int GenericDraweeHierarchy_roundTopRight = 18; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#roundWithOverlayColor} attribute's value can be found in the {@link #GenericDraweeHierarchy} array. <p>Must be a color value, in the form of "<code>#<i>rgb</i></code>", "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or "<code>#<i>aarrggbb</i></code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. @attr name com.bop.zz:roundWithOverlayColor */ public static final int GenericDraweeHierarchy_roundWithOverlayColor = 21; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#roundedCornerRadius} attribute's value can be found in the {@link #GenericDraweeHierarchy} array. <p>Must be a dimension value, which is a floating point number appended with a unit such as "<code>14.5sp</code>". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), mm (millimeters). <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. @attr name com.bop.zz:roundedCornerRadius */ public static final int GenericDraweeHierarchy_roundedCornerRadius = 16; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#roundingBorderColor} attribute's value can be found in the {@link #GenericDraweeHierarchy} array. <p>Must be a color value, in the form of "<code>#<i>rgb</i></code>", "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or "<code>#<i>aarrggbb</i></code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. @attr name com.bop.zz:roundingBorderColor */ public static final int GenericDraweeHierarchy_roundingBorderColor = 23; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#roundingBorderPadding} attribute's value can be found in the {@link #GenericDraweeHierarchy} array. <p>Must be a dimension value, which is a floating point number appended with a unit such as "<code>14.5sp</code>". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), mm (millimeters). <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. @attr name com.bop.zz:roundingBorderPadding */ public static final int GenericDraweeHierarchy_roundingBorderPadding = 24; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#roundingBorderWidth} attribute's value can be found in the {@link #GenericDraweeHierarchy} array. <p>Must be a dimension value, which is a floating point number appended with a unit such as "<code>14.5sp</code>". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), mm (millimeters). <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. @attr name com.bop.zz:roundingBorderWidth */ public static final int GenericDraweeHierarchy_roundingBorderWidth = 22; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#viewAspectRatio} attribute's value can be found in the {@link #GenericDraweeHierarchy} array. <p>Must be a floating point value, such as "<code>1.2</code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. @attr name com.bop.zz:viewAspectRatio */ public static final int GenericDraweeHierarchy_viewAspectRatio = 1; /** Attributes that can be used with a GifMoviewView. <p>Includes the following attributes:</p> <table> <colgroup align="left" /> <colgroup align="left" /> <tr><th>Attribute</th><th>Description</th></tr> <tr><td><code>{@link #GifMoviewView_gif com.bop.zz:gif}</code></td><td></td></tr> <tr><td><code>{@link #GifMoviewView_paused com.bop.zz:paused}</code></td><td></td></tr> </table> @see #GifMoviewView_gif @see #GifMoviewView_paused */ public static final int[] GifMoviewView = { 0x7f01003e, 0x7f01003f }; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#gif} attribute's value can be found in the {@link #GifMoviewView} array. <p>Must be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". @attr name com.bop.zz:gif */ public static final int GifMoviewView_gif = 0; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#paused} attribute's value can be found in the {@link #GifMoviewView} array. <p>Must be a boolean value, either "<code>true</code>" or "<code>false</code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. @attr name com.bop.zz:paused */ public static final int GifMoviewView_paused = 1; /** Attributes that can be used with a HorizontalListView. <p>Includes the following attributes:</p> <table> <colgroup align="left" /> <colgroup align="left" /> <tr><th>Attribute</th><th>Description</th></tr> <tr><td><code>{@link #HorizontalListView_android_divider android:divider}</code></td><td></td></tr> <tr><td><code>{@link #HorizontalListView_android_fadingEdgeLength android:fadingEdgeLength}</code></td><td></td></tr> <tr><td><code>{@link #HorizontalListView_android_requiresFadingEdge android:requiresFadingEdge}</code></td><td></td></tr> <tr><td><code>{@link #HorizontalListView_dividerWidth com.bop.zz:dividerWidth}</code></td><td></td></tr> </table> @see #HorizontalListView_android_divider @see #HorizontalListView_android_fadingEdgeLength @see #HorizontalListView_android_requiresFadingEdge @see #HorizontalListView_dividerWidth */ public static final int[] HorizontalListView = { 0x010100e0, 0x01010129, 0x010103a5, 0x7f010030 }; /** <p>This symbol is the offset where the {@link android.R.attr#divider} attribute's value can be found in the {@link #HorizontalListView} array. @attr name android:divider */ public static final int HorizontalListView_android_divider = 1; /** <p>This symbol is the offset where the {@link android.R.attr#fadingEdgeLength} attribute's value can be found in the {@link #HorizontalListView} array. @attr name android:fadingEdgeLength */ public static final int HorizontalListView_android_fadingEdgeLength = 0; /** <p>This symbol is the offset where the {@link android.R.attr#requiresFadingEdge} attribute's value can be found in the {@link #HorizontalListView} array. @attr name android:requiresFadingEdge */ public static final int HorizontalListView_android_requiresFadingEdge = 2; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#dividerWidth} attribute's value can be found in the {@link #HorizontalListView} array. <p>Must be a dimension value, which is a floating point number appended with a unit such as "<code>14.5sp</code>". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), mm (millimeters). <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. @attr name com.bop.zz:dividerWidth */ public static final int HorizontalListView_dividerWidth = 3; /** Attributes that can be used with a LoadingViewFinal. <p>Includes the following attributes:</p> <table> <colgroup align="left" /> <colgroup align="left" /> <tr><th>Attribute</th><th>Description</th></tr> <tr><td><code>{@link #LoadingViewFinal_loadMoreMode com.bop.zz:loadMoreMode}</code></td><td></td></tr> <tr><td><code>{@link #LoadingViewFinal_loadMoreView com.bop.zz:loadMoreView}</code></td><td></td></tr> <tr><td><code>{@link #LoadingViewFinal_noLoadMoreHideView com.bop.zz:noLoadMoreHideView}</code></td><td></td></tr> </table> @see #LoadingViewFinal_loadMoreMode @see #LoadingViewFinal_loadMoreView @see #LoadingViewFinal_noLoadMoreHideView */ public static final int[] LoadingViewFinal = { 0x7f01006d, 0x7f01006e, 0x7f01006f }; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#loadMoreMode} attribute's value can be found in the {@link #LoadingViewFinal} array. <p>Must be one or more (separated by '|') of the following constant values.</p> <table> <colgroup align="left" /> <colgroup align="left" /> <colgroup align="left" /> <tr><th>Constant</th><th>Value</th><th>Description</th></tr> <tr><td><code>click</code></td><td>0x0</td><td></td></tr> <tr><td><code>scroll</code></td><td>0x1</td><td></td></tr> </table> @attr name com.bop.zz:loadMoreMode */ public static final int LoadingViewFinal_loadMoreMode = 0; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#loadMoreView} attribute's value can be found in the {@link #LoadingViewFinal} array. <p>Must be a string value, using '\\;' to escape characters such as '\\n' or '\\uxxxx' for a unicode character. <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. @attr name com.bop.zz:loadMoreView */ public static final int LoadingViewFinal_loadMoreView = 1; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#noLoadMoreHideView} attribute's value can be found in the {@link #LoadingViewFinal} array. <p>Must be a boolean value, either "<code>true</code>" or "<code>false</code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. @attr name com.bop.zz:noLoadMoreHideView */ public static final int LoadingViewFinal_noLoadMoreHideView = 2; /** Attributes that can be used with a PtrClassicHeader. <p>Includes the following attributes:</p> <table> <colgroup align="left" /> <colgroup align="left" /> <tr><th>Attribute</th><th>Description</th></tr> <tr><td><code>{@link #PtrClassicHeader_ptr_rotate_ani_time com.bop.zz:ptr_rotate_ani_time}</code></td><td></td></tr> </table> @see #PtrClassicHeader_ptr_rotate_ani_time */ public static final int[] PtrClassicHeader = { 0x7f01006c }; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#ptr_rotate_ani_time} attribute's value can be found in the {@link #PtrClassicHeader} array. <p>Must be an integer value, such as "<code>100</code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. @attr name com.bop.zz:ptr_rotate_ani_time */ public static final int PtrClassicHeader_ptr_rotate_ani_time = 0; /** Attributes that can be used with a PtrFrameLayout. <p>Includes the following attributes:</p> <table> <colgroup align="left" /> <colgroup align="left" /> <tr><th>Attribute</th><th>Description</th></tr> <tr><td><code>{@link #PtrFrameLayout_ptr_content com.bop.zz:ptr_content}</code></td><td></td></tr> <tr><td><code>{@link #PtrFrameLayout_ptr_duration_to_close com.bop.zz:ptr_duration_to_close}</code></td><td></td></tr> <tr><td><code>{@link #PtrFrameLayout_ptr_duration_to_close_header com.bop.zz:ptr_duration_to_close_header}</code></td><td></td></tr> <tr><td><code>{@link #PtrFrameLayout_ptr_header com.bop.zz:ptr_header}</code></td><td> Optional.</td></tr> <tr><td><code>{@link #PtrFrameLayout_ptr_keep_header_when_refresh com.bop.zz:ptr_keep_header_when_refresh}</code></td><td> keep header when refreshing</td></tr> <tr><td><code>{@link #PtrFrameLayout_ptr_pull_to_fresh com.bop.zz:ptr_pull_to_fresh}</code></td><td> pull to refresh, otherwise release to refresh, default is release to refresh </td></tr> <tr><td><code>{@link #PtrFrameLayout_ptr_ratio_of_header_height_to_refresh com.bop.zz:ptr_ratio_of_header_height_to_refresh}</code></td><td> the ration of the height of the header to trigger refresh </td></tr> <tr><td><code>{@link #PtrFrameLayout_ptr_resistance com.bop.zz:ptr_resistance}</code></td><td> the resistance when you are moving the frame </td></tr> </table> @see #PtrFrameLayout_ptr_content @see #PtrFrameLayout_ptr_duration_to_close @see #PtrFrameLayout_ptr_duration_to_close_header @see #PtrFrameLayout_ptr_header @see #PtrFrameLayout_ptr_keep_header_when_refresh @see #PtrFrameLayout_ptr_pull_to_fresh @see #PtrFrameLayout_ptr_ratio_of_header_height_to_refresh @see #PtrFrameLayout_ptr_resistance */ public static final int[] PtrFrameLayout = { 0x7f010064, 0x7f010065, 0x7f010066, 0x7f010067, 0x7f010068, 0x7f010069, 0x7f01006a, 0x7f01006b }; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#ptr_content} attribute's value can be found in the {@link #PtrFrameLayout} array. <p>Must be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". @attr name com.bop.zz:ptr_content */ public static final int PtrFrameLayout_ptr_content = 1; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#ptr_duration_to_close} attribute's value can be found in the {@link #PtrFrameLayout} array. <p>Must be an integer value, such as "<code>100</code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. @attr name com.bop.zz:ptr_duration_to_close */ public static final int PtrFrameLayout_ptr_duration_to_close = 4; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#ptr_duration_to_close_header} attribute's value can be found in the {@link #PtrFrameLayout} array. <p>Must be an integer value, such as "<code>100</code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. @attr name com.bop.zz:ptr_duration_to_close_header */ public static final int PtrFrameLayout_ptr_duration_to_close_header = 5; /** <p> @attr description Optional. If you put header and content in xml, you can you these to specify them. <p>Must be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". <p>This is a private symbol. @attr name com.bop.zz:ptr_header */ public static final int PtrFrameLayout_ptr_header = 0; /** <p> @attr description keep header when refreshing <p>Must be a boolean value, either "<code>true</code>" or "<code>false</code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. <p>This is a private symbol. @attr name com.bop.zz:ptr_keep_header_when_refresh */ public static final int PtrFrameLayout_ptr_keep_header_when_refresh = 7; /** <p> @attr description pull to refresh, otherwise release to refresh, default is release to refresh <p>Must be a boolean value, either "<code>true</code>" or "<code>false</code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. <p>This is a private symbol. @attr name com.bop.zz:ptr_pull_to_fresh */ public static final int PtrFrameLayout_ptr_pull_to_fresh = 6; /** <p> @attr description the ration of the height of the header to trigger refresh <p>Must be a floating point value, such as "<code>1.2</code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. <p>This is a private symbol. @attr name com.bop.zz:ptr_ratio_of_header_height_to_refresh */ public static final int PtrFrameLayout_ptr_ratio_of_header_height_to_refresh = 3; /** <p> @attr description the resistance when you are moving the frame <p>Must be a floating point value, such as "<code>1.2</code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. <p>This is a private symbol. @attr name com.bop.zz:ptr_resistance */ public static final int PtrFrameLayout_ptr_resistance = 2; /** Attributes that can be used with a SimpleDraweeView. <p>Includes the following attributes:</p> <table> <colgroup align="left" /> <colgroup align="left" /> <tr><th>Attribute</th><th>Description</th></tr> <tr><td><code>{@link #SimpleDraweeView_actualImageUri com.bop.zz:actualImageUri}</code></td><td></td></tr> </table> @see #SimpleDraweeView_actualImageUri */ public static final int[] SimpleDraweeView = { 0x7f01001e }; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#actualImageUri} attribute's value can be found in the {@link #SimpleDraweeView} array. <p>Must be a string value, using '\\;' to escape characters such as '\\n' or '\\uxxxx' for a unicode character. <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. @attr name com.bop.zz:actualImageUri */ public static final int SimpleDraweeView_actualImageUri = 0; /** Attributes that can be used with a SwipeRefreshLayoutFinal. <p>Includes the following attributes:</p> <table> <colgroup align="left" /> <colgroup align="left" /> <tr><th>Attribute</th><th>Description</th></tr> <tr><td><code>{@link #SwipeRefreshLayoutFinal_refreshLoadingColor com.bop.zz:refreshLoadingColor}</code></td><td></td></tr> </table> @see #SwipeRefreshLayoutFinal_refreshLoadingColor */ public static final int[] SwipeRefreshLayoutFinal = { 0x7f010070 }; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#refreshLoadingColor} attribute's value can be found in the {@link #SwipeRefreshLayoutFinal} array. <p>Must be a color value, in the form of "<code>#<i>rgb</i></code>", "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or "<code>#<i>aarrggbb</i></code>". <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. @attr name com.bop.zz:refreshLoadingColor */ public static final int SwipeRefreshLayoutFinal_refreshLoadingColor = 0; /** Attributes that can be used with a ToggleButton. <p>Includes the following attributes:</p> <table> <colgroup align="left" /> <colgroup align="left" /> <tr><th>Attribute</th><th>Description</th></tr> <tr><td><code>{@link #ToggleButton_tbAnimate com.bop.zz:tbAnimate}</code></td><td></td></tr> <tr><td><code>{@link #ToggleButton_tbAsDefaultOn com.bop.zz:tbAsDefaultOn}</code></td><td></td></tr> <tr><td><code>{@link #ToggleButton_tbBorderWidth com.bop.zz:tbBorderWidth}</code></td><td></td></tr> <tr><td><code>{@link #ToggleButton_tbOffBorderColor com.bop.zz:tbOffBorderColor}</code></td><td></td></tr> <tr><td><code>{@link #ToggleButton_tbOffColor com.bop.zz:tbOffColor}</code></td><td></td></tr> <tr><td><code>{@link #ToggleButton_tbOnColor com.bop.zz:tbOnColor}</code></td><td></td></tr> <tr><td><code>{@link #ToggleButton_tbSpotColor com.bop.zz:tbSpotColor}</code></td><td></td></tr> </table> @see #ToggleButton_tbAnimate @see #ToggleButton_tbAsDefaultOn @see #ToggleButton_tbBorderWidth @see #ToggleButton_tbOffBorderColor @see #ToggleButton_tbOffColor @see #ToggleButton_tbOnColor @see #ToggleButton_tbSpotColor */ public static final int[] ToggleButton = { 0x7f010052, 0x7f010053, 0x7f010054, 0x7f010055, 0x7f010056, 0x7f010057, 0x7f010058 }; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#tbAnimate} attribute's value can be found in the {@link #ToggleButton} array. <p>May be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". <p>May be a boolean value, either "<code>true</code>" or "<code>false</code>". @attr name com.bop.zz:tbAnimate */ public static final int ToggleButton_tbAnimate = 5; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#tbAsDefaultOn} attribute's value can be found in the {@link #ToggleButton} array. <p>May be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". <p>May be a boolean value, either "<code>true</code>" or "<code>false</code>". @attr name com.bop.zz:tbAsDefaultOn */ public static final int ToggleButton_tbAsDefaultOn = 6; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#tbBorderWidth} attribute's value can be found in the {@link #ToggleButton} array. <p>Must be a dimension value, which is a floating point number appended with a unit such as "<code>14.5sp</code>". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), mm (millimeters). <p>This may also be a reference to a resource (in the form "<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or theme attribute (in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") containing a value of this type. @attr name com.bop.zz:tbBorderWidth */ public static final int ToggleButton_tbBorderWidth = 0; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#tbOffBorderColor} attribute's value can be found in the {@link #ToggleButton} array. <p>May be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or "<code>#<i>aarrggbb</i></code>". @attr name com.bop.zz:tbOffBorderColor */ public static final int ToggleButton_tbOffBorderColor = 1; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#tbOffColor} attribute's value can be found in the {@link #ToggleButton} array. <p>May be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or "<code>#<i>aarrggbb</i></code>". @attr name com.bop.zz:tbOffColor */ public static final int ToggleButton_tbOffColor = 2; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#tbOnColor} attribute's value can be found in the {@link #ToggleButton} array. <p>May be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or "<code>#<i>aarrggbb</i></code>". @attr name com.bop.zz:tbOnColor */ public static final int ToggleButton_tbOnColor = 3; /** <p>This symbol is the offset where the {@link com.bop.zz.R.attr#tbSpotColor} attribute's value can be found in the {@link #ToggleButton} array. <p>May be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or "<code>#<i>aarrggbb</i></code>". @attr name com.bop.zz:tbSpotColor */ public static final int ToggleButton_tbSpotColor = 4; }; }
ahai3840/slate-editor
lib/plugins/slate-helper-block-cleardatabykey/src/index.js
<filename>lib/plugins/slate-helper-block-cleardatabykey/src/index.js "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); /** * this delete a data key in current block type * * @param {Slate.state} state * @param {Datakey} dataKey * @return {Slate.state} **/ exports.default = function (change, dataKey) { var value = change.value; var blocks = value.blocks; // if have blocks if (blocks) { blocks.forEach(function (type) { var typeOriginalData = type.get("data"); var newData = typeOriginalData.delete(dataKey); var newType = type.set("data", newData); // reset current type with new data change.setBlocks(newType); }); } return change; };
abhinavsri360/Allcodes
JCode/hello/TrinomialDP.java
public class TrinomialDP { public static void main(String[] args) { int n = Integer.parseInt(args[0]); int k = Integer.parseInt(args[1]); System.out.println(trinomial(n, k)); } public static long trinomial(int n, int k) { if (n == 0 && k == 0) return 1; else if (k > n || k < -n) return 0; long[][] a = new long[n + 1][n + 2]; a[0][1] = a[1][0] = a[1][1] = a[1][2] = 1; for (int i = 2; i < n + 1; i++) { for (int j = 1; j < n + 2; j++) { if (j < n + 1) a[i][j] = a[i - 1][j - 1] + a[i - 1][j] + a[i - 1][j + 1]; else a[i][j] = a[i - 1][j - 1] + a[i - 1][j]; a[i][0] = a[i][2]; } } if (k > 0) return a[n][k + 1]; else return a[n][-k + 1]; } }
htouqeer938/pet-hotel
3-Customization/22-Only Managers can register Employees and other Managers/backend-sql/src/api/iam/mutations/iamRemove.js
<gh_stars>0 const IamRemover = require('../../../services/iam/iamRemover'); const PermissionChecker = require('../../../services/iam/permissionChecker'); const permissions = require('../../../security/permissions') .values; const schema = ` iamRemove(emails: [ String! ]!, roles: [ String! ]!, all: Boolean): Boolean `; const resolver = { iamRemove: async (root, args, context) => { new PermissionChecker(context).validateHas( permissions.iamRemove, ); let remover = new IamRemover( context.currentUser, context.language, ); await remover.removeAll(args); return true; }, }; exports.schema = schema; exports.resolver = resolver;
atpollmann/Reservation-system
agendator2000/server/src/cl/usach/ingesoft/agendator/business/service/IAdministrationService.java
package cl.usach.ingesoft.agendator.business.service; import cl.usach.ingesoft.agendator.entity.CareSessionEntity; import cl.usach.ingesoft.agendator.entity.OngEntity; import java.util.Date; import java.util.List; public interface IAdministrationService { /** * Operation 5. * * @param careSession Creates a new CareSession for the given parameters. * @return just created CareSession. */ CareSessionEntity createCareSession(CareSessionEntity careSession); /** * Operation 6. * * Cancels a CareSession (this does not deletes it). * * @param idCareSession Id for the CareSession to be canceled. * @return whether the CareSession could be canceled or not (true means canceled, otherwise false). */ boolean cancelCareSession(int idCareSession); /** * Operation 7. * * @param careSession CareSession to be updated. * @return CareSession just updated. */ CareSessionEntity updateCareSession(CareSessionEntity careSession); /** * * @param ongId Id for the Ong to retrieve. * @return Ong for the id provided, or null if none was found. */ OngEntity findCurrentOng(int ongId); OngEntity findCurrentOng(); /** * * @param ong Ong for which the CareSession is to be retrieved. * @param currentTime Date and time for which the CareSession is to be retrieved. * @return CareSession for the supplied parameters (or null if none was found). */ CareSessionEntity findCurrentCareSession(OngEntity ong, Date currentTime); List<CareSessionEntity> findAllCareSessions(int ongId); List<CareSessionEntity> findPendingCareSessions(int ongId, Date currentDate); /** * * @param idCareSession If for the CareSession to be retrieved. * @return CareSession for the provided id, or null if none was found. */ CareSessionEntity findCareSessionById(int idCareSession); }
kaixiang1992/python-flask
502/modes.py
from sqlalchemy import create_engine, Column, Integer, String, DATETIME from sqlalchemy.ext.declarative import declarative_base from datetime import datetime # TODO: db_uri # dialect+driver://username:password@host:port/database?charset=utf8 DB_URI = 'mysql+pymysql://root:root123@127.0.0.1:3300/alembic_demo?charset=utf8' engine = create_engine(DB_URI) Base = declarative_base(bind=engine) # TODO: 定义User模型 class User(Base): __tablename__ = 'user' id = Column(Integer, primary_key=True, autoincrement=True) name = Column(String(50), nullable=False) # TODO: 增加字段 age = Column(Integer, nullable=False) country = Column(String(50), nullable=False) create_time = Column(DATETIME, default=datetime.now)
omserta/xsocs
xsocs/gui/widgets/AcqParamsWidget.py
<reponame>omserta/xsocs # coding: utf-8 # /*########################################################################## # # Copyright (c) 2015-2016 European Synchrotron Radiation Facility # # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated documentation files (the "Software"), to deal # in the Software without restriction, including without limitation the rights # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell # copies of the Software, and to permit persons to whom the Software is # furnished to do so, subject to the following conditions: # # The above copyright notice and this permission notice shall be included in # all copies or substantial portions of the Software. # # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER # LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN # THE SOFTWARE. # # ###########################################################################*/ from __future__ import absolute_import __authors__ = ["<NAME>"] __license__ = "MIT" __date__ = "15/09/2016" from silx.gui import qt as Qt from .Input import StyledLineEdit _MU_LOWER = u'\u03BC' _PHI_LOWER = u'\u03C6' _ETA_LOWER = u'\u03B7' class AcqParamsWidget(Qt.QWidget): def __init__(self, read_only=False, **kwargs): super(AcqParamsWidget, self).__init__(**kwargs) layout = Qt.QGridLayout(self) layout.setContentsMargins(0, 0, 0, 0) self.__read_only = read_only self.__beam_energy = None self.__dir_beam_h = None self.__dir_beam_v = None self.__chpdeg_h = None self.__chpdeg_v = None class DblValidator(Qt.QDoubleValidator): def validate(self, text, pos): if len(text) == 0: return Qt.QValidator.Acceptable, text, pos return super(DblValidator, self).validate(text, pos) def dblLineEditWidget(width): wid = StyledLineEdit(nChar=width, readOnly=read_only) wid.setValidator(DblValidator()) return wid # =========== # beam energy # =========== row = 0 h_layout = Qt.QHBoxLayout() beam_nrg_edit = dblLineEditWidget(8) h_layout.addWidget(beam_nrg_edit) h_layout.addWidget(Qt.QLabel('<b>eV</b>')) layout.addWidget(Qt.QLabel('Beam energy :'), row, 0) layout.addLayout(h_layout, row, 1, alignment=Qt.Qt.AlignLeft | Qt.Qt.AlignTop) # === row += 1 h_line = Qt.QFrame() h_line.setFrameShape(Qt.QFrame.HLine) h_line.setFrameShadow(Qt.QFrame.Sunken) layout.addWidget(h_line, row, 0, 1, 2) # =========== # direct beam # =========== row += 1 h_layout = Qt.QHBoxLayout() layout.addLayout(h_layout, row, 1, alignment=Qt.Qt.AlignLeft | Qt.Qt.AlignTop) dir_beam_h_edit = dblLineEditWidget(6) h_layout.addWidget(Qt.QLabel('v=')) h_layout.addWidget(dir_beam_h_edit) dir_beam_v_edit = dblLineEditWidget(6) h_layout.addWidget(Qt.QLabel(' h=')) h_layout.addWidget(dir_beam_v_edit) h_layout.addWidget(Qt.QLabel('<b>px</b>')) layout.addWidget(Qt.QLabel('Direct beam :'), row, 0) # === row += 1 h_line = Qt.QFrame() h_line.setFrameShape(Qt.QFrame.HLine) h_line.setFrameShadow(Qt.QFrame.Sunken) layout.addWidget(h_line, row, 0, 1, 3) # =========== # chan per degree # =========== row += 1 h_layout = Qt.QHBoxLayout() layout.addLayout(h_layout, row, 1, alignment=Qt.Qt.AlignLeft | Qt.Qt.AlignTop) chpdeg_h_edit = dblLineEditWidget(6) h_layout.addWidget(Qt.QLabel('v=')) h_layout.addWidget(chpdeg_h_edit) chpdeg_v_edit = dblLineEditWidget(6) h_layout.addWidget(Qt.QLabel(' h=')) h_layout.addWidget(chpdeg_v_edit) h_layout.addWidget(Qt.QLabel('<b>px</b>')) layout.addWidget(Qt.QLabel('Chan. per deg. :'), row, 0) # === row += 1 h_line = Qt.QFrame() h_line.setFrameShape(Qt.QFrame.HLine) h_line.setFrameShadow(Qt.QFrame.Sunken) layout.addWidget(h_line, row, 0, 1, 3) # =========== # size constraints # =========== self.setSizePolicy(Qt.QSizePolicy(Qt.QSizePolicy.Fixed, Qt.QSizePolicy.Fixed)) # named tuple with references to all the important widgets self.__beam_nrg_edit = beam_nrg_edit self.__dir_beam_h_edit = dir_beam_h_edit self.__dir_beam_v_edit = dir_beam_v_edit self.__chpdeg_h_edit = chpdeg_h_edit self.__chpdeg_v_edit = chpdeg_v_edit def clear(self): self.__beam_nrg_edit.clear() self.__dir_beam_h_edit.clear() self.__dir_beam_v_edit.clear() self.__chpdeg_h_edit.clear() self.__chpdeg_v_edit.clear() @property def beam_energy(self): text = self.__beam_nrg_edit.text() if len(text) == 0: return None return float(text) @beam_energy.setter def beam_energy(self, beam_energy): self.__beam_nrg_edit.setText(str(beam_energy)) self.__beam_energy = beam_energy @property def direct_beam_h(self): text = self.__dir_beam_h_edit.text() if len(text) == 0: return None return float(text) @direct_beam_h.setter def direct_beam_h(self, direct_beam_h): self.__dir_beam_h_edit.setText(str(direct_beam_h)) self.__dir_beam_h = direct_beam_h @property def direct_beam_v(self): text = self.__dir_beam_v_edit.text() if len(text) == 0: return None return float(text) @direct_beam_v.setter def direct_beam_v(self, direct_beam_v): self.__dir_beam_v_edit.setText(str(direct_beam_v)) self.__dir_beam_v = direct_beam_v @property def chperdeg_h(self): text = self.__chpdeg_h_edit.text() if len(text) == 0: return None return float(text) @chperdeg_h.setter def chperdeg_h(self, chperdeg_h): self.__chpdeg_h_edit.setText(str(chperdeg_h)) self.__chpdeg_h = chperdeg_h @property def chperdeg_v(self): text = self.__chpdeg_v_edit.text() if len(text) == 0: return None return float(text) @chperdeg_v.setter def chperdeg_v(self, chperdeg_v): self.__chpdeg_v_edit.setText(str(chperdeg_v)) self.__chpdeg_v = chperdeg_v if __name__ == '__main__': pass
anant0301/Sem5
Computer Networks/Networkings Lab/Huffman_Encoding/huffman_encoding/create_node.c
#include "../headers.h" struct huffman_node* create_node(struct huffman_heap* tree, char ch) { struct huffman_node *node = (struct huffman_node*)malloc(sizeof(struct huffman_node)); node-> data = ch; node-> freq = 1; node-> left_ = NULL; node-> right_ = NULL; bzero(node-> code, MAX_ENCODE_LEN); tree-> length++; return node; }
izenecloud/sf1r-lite
source/core/common/Utilities.h
#ifndef SF1R_COMMON_UTILITY_H #define SF1R_COMMON_UTILITY_H #include <sf1common/Utilities.h> namespace sf1r { using izenelib::Utilities; } #endif
truhlikfredy/dcs-bios-2-stream-deck
src/modules/allModules.js
<filename>src/modules/allModules.js module.exports = [ require('./deck15/ka-50/default.js') ]
LewJun/spring-boot-demo
spring-boot-mapstruct/src/main/java/com/example/lewjun/domain/bo/BaseObj.java
package com.example.lewjun.domain.bo; import com.fasterxml.jackson.annotation.JsonInclude; import java.io.Serializable; // 若为null,则不要返回给前端 @JsonInclude(JsonInclude.Include.NON_NULL) public class BaseObj implements Serializable { }
rbtnn/Admin
app/helpers/format-number.js
<filename>app/helpers/format-number.js import {helper} from '@ember/component/helper'; export function formatNumber(number, options) { if (number === '' || number === null || number === undefined) { return; } return Number(number).toLocaleString(undefined, options); } export default helper(function ([number]/*, hash*/) { return formatNumber(number); });
ehbc221/apprenez-a-programmer-en-python
autres/fichiers/fichiers.py
# -*-coding:Utf-8 -* ############################################ # Changer le répertoire de travail courant # ############################################ import os os.chdir("/var/www/html/openclassrooms-apprenez-a-programmer-en-python/autres/fichiers") ########################### # Lecture dans un fichier # ########################### # Ouverture du fichier mon_fichier = open("fichier.txt", "r") # open(chemin, mode) : mode = "r" (read), "w" (write), "a" (append) # Fermer le fichier mon_fichier.close() # Lire l'intégralité du fichier mon_fichier = open("fichier.txt", "r") contenu = mon_fichier.read() print(contenu) # C'est le contenu du fichier. Spectaculaire non ? mon_fichier.close() ############################ # Écriture dans un fichier # ############################ # Écrire une chaîne mon_fichier = open("fichier.txt", "w") # Argh j'ai tout écrasé ! mon_fichier.write("Premier test d'écriture dans un fichier via Python") # renvoie le nombre de caractères écrites : 50 mon_fichier.close() # Écrire d'autres types de données (il faut d'abord les convertir en chaine de caractères car write ne prend que les chaines) mon_fichier = open("fichier.txt", "w") # Argh j'ai tout écrasé ! score = 400 # Un score pris au hasard (entier) score = str(score) # on converti le score en chaine de caractères mon_fichier.write(score) # renvoie le nombre de caractères écrites : 50 mon_fichier.close() # Le mot-clé with : Cela signifie simplement que, si une exception se produit, le fichier sera tout de même fermé à la fin du bloc. with open('fichier.txt', 'r') as mon_fichier: texte = mon_fichier.read() ############################################ # Enregistrer des objets dans des fichiers # ############################################ # Tout d'abord, il faut importer le module pickle import pickle # Enregistrer un objet dans un fichier score = { "joueur 1": 5, "joueur 2": 35, "joueur 3": 20, "joueur 4": 2 } with open('donnees', 'wb') as fichier: mon_pickler = pickle.Pickler(fichier) mon_pickler.dump(score) # Récupérer nos objets enregistrés with open('donnees', 'rb') as fichier: mon_depickler = pickle.Unpickler(fichier) score_recupere = mon_depickler.load() print(score_recupere)
ximingxing/Close-Look-Java
Code/22-Generate-Parentheses/src/Solution.java
import java.util.LinkedList; import java.util.List; /** * Description: 括号生成 * Solution: 回溯 + 减枝 * Created By xingximing.xxm */ public class Solution { // 保存全部结果的集合 List<String> res = new LinkedList<>(); public List<String> generateParenthesis(int n) { backtrace(n, n, ""); return res; } /** * "回溯 + 剪枝"生成全部合法的括号 * * @param left 剩余可用的左括号数目 * @param right 剩余可用的右括号的数目 * @param path DFS轨迹,即当前括号合集 */ private void backtrace(int left, int right, String path) { if (left == 0 && right == 0) { res.add(path); return; } // 剪枝:任何时候左括号的数目都小于右括号的数目 if (left > right) return; if (left > 0) { backtrace(left - 1, right, path + "("); } if (right > 0) { backtrace(left, right - 1, path + ")"); } } public static void main(String[] args) { List<String> strings = new Solution().generateParenthesis(3); for (String string : strings) { System.out.println(string); } } }
pierreloicq/OsmAnd-core
include/OsmAndCore/Map/MapPrimitiviser.h
#ifndef _OSMAND_CORE_MAP_PRIMITIVISER_H_ #define _OSMAND_CORE_MAP_PRIMITIVISER_H_ #include <OsmAndCore/stdlib_common.h> #include <functional> #include <array> #include <OsmAndCore/QtExtensions.h> #include <QList> #include <OsmAndCore.h> #include <OsmAndCore/CommonTypes.h> #include <OsmAndCore/PrivateImplementation.h> #include <OsmAndCore/IQueryController.h> #include <OsmAndCore/SharedResourcesContainer.h> #include <OsmAndCore/Data/MapObject.h> #include <OsmAndCore/Map/MapCommonTypes.h> #include <OsmAndCore/Map/MapStyleEvaluationResult.h> #include <OsmAndCore/Map/MapPrimitiviser_Metrics.h> namespace OsmAnd { class MapObject; class MapPresentationEnvironment; class MapPrimitiviser_P; class OSMAND_CORE_API MapPrimitiviser { Q_DISABLE_COPY_AND_MOVE(MapPrimitiviser); public: enum class PrimitiveType : uint32_t { Point = 1, Polyline = 2, Polygon = 3, }; enum { LastZoomToUseBasemap = ZoomLevel11, DetailedLandDataMinZoom = ZoomLevel14, DefaultTextLabelWrappingLengthInCharacters = 20 }; class OSMAND_CORE_API CoastlineMapObject : public MapObject { Q_DISABLE_COPY_AND_MOVE(CoastlineMapObject); private: protected: public: CoastlineMapObject(); virtual ~CoastlineMapObject(); }; class OSMAND_CORE_API SurfaceMapObject : public MapObject { Q_DISABLE_COPY_AND_MOVE(SurfaceMapObject); private: protected: public: SurfaceMapObject(); virtual ~SurfaceMapObject(); }; class Primitive; typedef QList< std::shared_ptr<const Primitive> > PrimitivesCollection; class PrimitivesGroup; typedef QList< std::shared_ptr<const PrimitivesGroup> > PrimitivesGroupsCollection; class OSMAND_CORE_API PrimitivesGroup Q_DECL_FINAL { Q_DISABLE_COPY_AND_MOVE(PrimitivesGroup); private: protected: PrimitivesGroup(const std::shared_ptr<const MapObject>& sourceObject); public: ~PrimitivesGroup(); const std::shared_ptr<const MapObject> sourceObject; PrimitivesCollection polygons; PrimitivesCollection polylines; PrimitivesCollection points; friend class OsmAnd::MapPrimitiviser; friend class OsmAnd::MapPrimitiviser_P; }; class OSMAND_CORE_API Primitive Q_DECL_FINAL { Q_DISABLE_COPY_AND_MOVE(Primitive); private: protected: Primitive( const std::shared_ptr<const PrimitivesGroup>& group, const PrimitiveType type, const uint32_t typeRuleIdIndex); Primitive( const std::shared_ptr<const PrimitivesGroup>& group, const PrimitiveType type, const uint32_t typeRuleIdIndex, const MapStyleEvaluationResult& evaluationResult); public: ~Primitive(); const std::weak_ptr<const PrimitivesGroup> group; const std::shared_ptr<const MapObject> sourceObject; const PrimitiveType type; const uint32_t attributeIdIndex; const MapStyleEvaluationResult::Packed evaluationResult; int zOrder; int64_t doubledArea; friend class OsmAnd::MapPrimitiviser; friend class OsmAnd::MapPrimitiviser_P; }; class Symbol; typedef QList< std::shared_ptr<const Symbol> > SymbolsCollection; class SymbolsGroup; typedef QHash< std::shared_ptr<const MapObject>, std::shared_ptr<const SymbolsGroup> > SymbolsGroupsCollection; class OSMAND_CORE_API SymbolsGroup Q_DECL_FINAL { Q_DISABLE_COPY_AND_MOVE(SymbolsGroup); private: protected: SymbolsGroup( const std::shared_ptr<const MapObject>& sourceObject); public: ~SymbolsGroup(); const std::shared_ptr<const MapObject> sourceObject; SymbolsCollection symbols; friend class OsmAnd::MapPrimitiviser; friend class OsmAnd::MapPrimitiviser_P; }; class OSMAND_CORE_API Symbol { Q_DISABLE_COPY_AND_MOVE(Symbol); private: protected: Symbol(const std::shared_ptr<const Primitive>& primitive); public: virtual ~Symbol(); const std::shared_ptr<const Primitive> primitive; PointI location31; int order; bool drawAlongPath; QSet<QString> intersectsWith; float intersectionSizeFactor; float intersectionSize; float intersectionMargin; float minDistance; float scaleFactor; bool operator==(const Symbol& that) const; bool operator!=(const Symbol& that) const; bool hasSameContentAs(const Symbol& that) const; bool hasDifferentContentAs(const Symbol& that) const; friend class OsmAnd::MapPrimitiviser; friend class OsmAnd::MapPrimitiviser_P; }; class OSMAND_CORE_API TextSymbol : public Symbol { Q_DISABLE_COPY_AND_MOVE(TextSymbol); private: protected: TextSymbol(const std::shared_ptr<const Primitive>& primitive); public: virtual ~TextSymbol(); QString value; LanguageId languageId; bool drawOnPath; int verticalOffset; ColorARGB color; int size; int shadowRadius; ColorARGB shadowColor; int wrapWidth; bool isBold; bool isItalic; QString shieldResourceName; QString underlayIconResourceName; bool operator==(const TextSymbol& that) const; bool operator!=(const TextSymbol& that) const; bool hasSameContentAs(const TextSymbol& that) const; bool hasDifferentContentAs(const TextSymbol& that) const; friend class OsmAnd::MapPrimitiviser; friend class OsmAnd::MapPrimitiviser_P; }; class OSMAND_CORE_API IconSymbol : public Symbol { Q_DISABLE_COPY_AND_MOVE(IconSymbol); private: protected: IconSymbol(const std::shared_ptr<const Primitive>& primitive); public: virtual ~IconSymbol(); QString resourceName; QList<QString> underlayResourceNames; QList<QString> overlayResourceNames; PointF offsetFactor; QString shieldResourceName; bool operator==(const IconSymbol& that) const; bool operator!=(const IconSymbol& that) const; bool hasSameContentAs(const IconSymbol& that) const; bool hasDifferentContentAs(const IconSymbol& that) const; friend class OsmAnd::MapPrimitiviser; friend class OsmAnd::MapPrimitiviser_P; }; class OSMAND_CORE_API Cache { Q_DISABLE_COPY_AND_MOVE(Cache); public: typedef SharedResourcesContainer<MapObject::SharingKey, const PrimitivesGroup> SharedPrimitivesGroupsContainer; typedef SharedResourcesContainer<MapObject::SharingKey, const SymbolsGroup> SharedSymbolsGroupsContainer; private: protected: std::array<SharedPrimitivesGroupsContainer, ZoomLevelsCount> _sharedPrimitivesGroups; std::array<SharedSymbolsGroupsContainer, ZoomLevelsCount> _sharedSymbolsGroups; public: Cache(); virtual ~Cache(); virtual SharedPrimitivesGroupsContainer& getPrimitivesGroups(const ZoomLevel zoom); virtual const SharedPrimitivesGroupsContainer& getPrimitivesGroups(const ZoomLevel zoom) const; virtual SharedSymbolsGroupsContainer& getSymbolsGroups(const ZoomLevel zoom); virtual const SharedSymbolsGroupsContainer& getSymbolsGroups(const ZoomLevel zoom) const; SharedPrimitivesGroupsContainer* getPrimitivesGroupsPtr(const ZoomLevel zoom); const SharedPrimitivesGroupsContainer* getPrimitivesGroupsPtr(const ZoomLevel zoom) const; SharedSymbolsGroupsContainer* getSymbolsGroupsPtr(const ZoomLevel zoom); const SharedSymbolsGroupsContainer* getSymbolsGroupsPtr(const ZoomLevel zoom) const; }; class OSMAND_CORE_API PrimitivisedObjects Q_DECL_FINAL { Q_DISABLE_COPY_AND_MOVE(PrimitivisedObjects); private: const std::weak_ptr<Cache> _cache; protected: PrimitivisedObjects( const std::shared_ptr<const MapPresentationEnvironment>& mapPresentationEnvironment, const std::shared_ptr<Cache>& cache, const ZoomLevel zoom, const PointD scaleDivisor31ToPixel); public: ~PrimitivisedObjects(); const std::shared_ptr<const MapPresentationEnvironment> mapPresentationEnvironment; const ZoomLevel zoom; const PointD scaleDivisor31ToPixel; PrimitivesGroupsCollection primitivesGroups; PrimitivesCollection polygons; PrimitivesCollection polylines; PrimitivesCollection points; SymbolsGroupsCollection symbolsGroups; bool isEmpty() const; friend class OsmAnd::MapPrimitiviser; friend class OsmAnd::MapPrimitiviser_P; }; private: PrivateImplementation<MapPrimitiviser_P> _p; protected: public: MapPrimitiviser(const std::shared_ptr<const MapPresentationEnvironment>& environment); virtual ~MapPrimitiviser(); const std::shared_ptr<const MapPresentationEnvironment> environment; std::shared_ptr<PrimitivisedObjects> primitiviseAllMapObjects( const ZoomLevel zoom, const QList< std::shared_ptr<const MapObject> >& objects, const std::shared_ptr<Cache>& cache = nullptr, const std::shared_ptr<const IQueryController>& queryController = nullptr, MapPrimitiviser_Metrics::Metric_primitiviseAllMapObjects* const metric = nullptr); std::shared_ptr<PrimitivisedObjects> primitiviseAllMapObjects( const PointD scaleDivisor31ToPixel, const ZoomLevel zoom, const QList< std::shared_ptr<const MapObject> >& objects, const std::shared_ptr<Cache>& cache = nullptr, const std::shared_ptr<const IQueryController>& queryController = nullptr, MapPrimitiviser_Metrics::Metric_primitiviseAllMapObjects* const metric = nullptr); std::shared_ptr<PrimitivisedObjects> primitiviseWithSurface( const AreaI area31, const PointI areaSizeInPixels, const ZoomLevel zoom, const MapSurfaceType surfaceType, const QList< std::shared_ptr<const MapObject> >& objects, const std::shared_ptr<Cache>& cache = nullptr, const std::shared_ptr<const IQueryController>& queryController = nullptr, MapPrimitiviser_Metrics::Metric_primitiviseWithSurface* const metric = nullptr); std::shared_ptr<PrimitivisedObjects> primitiviseWithoutSurface( const PointD scaleDivisor31ToPixel, const ZoomLevel zoom, const QList< std::shared_ptr<const MapObject> >& objects, const std::shared_ptr<Cache>& cache = nullptr, const std::shared_ptr<const IQueryController>& queryController = nullptr, MapPrimitiviser_Metrics::Metric_primitiviseWithoutSurface* const metric = nullptr); }; } #endif // !defined(_OSMAND_CORE_MAP_PRIMITIVISER_H_)
lowlander/nederrock
src/parser_nodes/literal_parser_node.hpp
<gh_stars>0 // // Copyright (c) 2020 <NAME> <<EMAIL>> // // SPDX-License-Identifier: MIT // #ifndef NEDERROCK_SRC_LITERAL_PARSER_NODE_HPP #define NEDERROCK_SRC_LITERAL_PARSER_NODE_HPP #include "literal_parser_node_pre.hpp" #include "constant_parser_node_pre.hpp" #include "number_parser_node_pre.hpp" #include "string_parser_node_pre.hpp" #include "token_stream.hpp" #include "scope_state.hpp" #include <memory> #include <istream> #include <variant> class Literal_Parser_Node { private: struct Choice_1 { void dump(std::wostream& output) const; void generate_cpp(Scope_State_Ptr state) const; Constant_Parser_Node_Ptr m_constant; }; struct Choice_2 { void dump(std::wostream& output) const; void generate_cpp(Scope_State_Ptr state) const; Number_Parser_Node_Ptr m_number; }; struct Choice_3 { void dump(std::wostream& output) const; void generate_cpp(Scope_State_Ptr state) const; String_Parser_Node_Ptr m_string; }; public: Literal_Parser_Node(Choice_1&& choice); Literal_Parser_Node(Choice_2&& choice); Literal_Parser_Node(Choice_3&& choice); static Literal_Parser_Node_Ptr parse_choice_1(Token_Stream& input); static Literal_Parser_Node_Ptr parse_choice_2(Token_Stream& input); static Literal_Parser_Node_Ptr parse_choice_3(Token_Stream& input); static Literal_Parser_Node_Ptr parse(Token_Stream& input); void dump(std::wostream& output) const; void generate_cpp(Scope_State_Ptr state) const; private: std::variant<Choice_1, Choice_2, Choice_3> m_choice; }; #endif // NEDERROCK_SRC_LITERAL_PARSER_NODE_HPP
Andreas237/AndroidPolicyAutomation
ExtractedJars/RT_News_com.rt.mobile.english/javafiles/com/google/android/gms/internal/ads/zzahn.java
// Decompiled by Jad v1.5.8g. Copyright 2001 <NAME>. // Jad home page: http://www.kpdus.com/jad.html // Decompiler options: packimports(3) annotate safe package com.google.android.gms.internal.ads; import android.content.Context; import android.os.*; import com.google.android.gms.ads.internal.gmsg.zzb; import com.google.android.gms.ads.internal.zzbv; import com.google.android.gms.common.util.Clock; import java.util.concurrent.Future; // Referenced classes of package com.google.android.gms.internal.ads: // zzajx, zzaht, zzahw, zzaia, // zzaib, zzahv, zzwx, zzxq, // zzakb, zzaji, zzaef, zzamu, // zzaho, zzahp, zzahs, zzanz, // zzahq, zzjj public final class zzahn extends zzajx implements zzaht, zzahw, zzaia { public zzahn(Context context, String s, String s1, zzwx zzwx1, zzaji zzaji1, zzaib zzaib1, zzahw zzahw1, long l) { // 0 0:aload_0 // 1 1:invokespecial #42 <Method void zzajx()> zzclq = 0; // 2 4:aload_0 // 3 5:iconst_0 // 4 6:putfield #44 <Field int zzclq> mErrorCode = 3; // 5 9:aload_0 // 6 10:iconst_3 // 7 11:putfield #46 <Field int mErrorCode> mContext = context; // 8 14:aload_0 // 9 15:aload_1 // 10 16:putfield #48 <Field Context mContext> zzbth = s; // 11 19:aload_0 // 12 20:aload_2 // 13 21:putfield #50 <Field String zzbth> zzcln = s1; // 14 24:aload_0 // 15 25:aload_3 // 16 26:putfield #52 <Field String zzcln> zzclo = zzwx1; // 17 29:aload_0 // 18 30:aload 4 // 19 32:putfield #54 <Field zzwx zzclo> zzbze = zzaji1; // 20 35:aload_0 // 21 36:aload 5 // 22 38:putfield #56 <Field zzaji zzbze> zzcll = zzaib1; // 23 41:aload_0 // 24 42:aload 6 // 25 44:putfield #58 <Field zzaib zzcll> // 26 47:aload_0 // 27 48:new #60 <Class Object> // 28 51:dup // 29 52:invokespecial #61 <Method void Object()> // 30 55:putfield #63 <Field Object mLock> zzclm = zzahw1; // 31 58:aload_0 // 32 59:aload 7 // 33 61:putfield #65 <Field zzahw zzclm> zzclp = l; // 34 64:aload_0 // 35 65:lload 8 // 36 67:putfield #67 <Field long zzclp> // 37 70:return } static Context zza(zzahn zzahn1) { return zzahn1.mContext; // 0 0:aload_0 // 1 1:getfield #48 <Field Context mContext> // 2 4:areturn } static void zza(zzahn zzahn1, zzjj zzjj, zzxq zzxq1) { zzahn1.zza(zzjj, zzxq1); // 0 0:aload_0 // 1 1:aload_1 // 2 2:aload_2 // 3 3:invokespecial #74 <Method void zza(zzjj, zzxq)> // 4 6:return } private final void zza(zzjj zzjj, zzxq zzxq1) { zzcll.zzpf().zza(((zzahw) (this))); // 0 0:aload_0 // 1 1:getfield #58 <Field zzaib zzcll> // 2 4:invokevirtual #82 <Method zzahv zzaib.zzpf()> // 3 7:aload_0 // 4 8:invokevirtual #87 <Method void zzahv.zza(zzahw)> if("com.google.ads.mediation.admob.AdMobAdapter".equals(((Object) (zzbth)))) //* 5 11:ldc1 #89 <String "com.google.ads.mediation.admob.AdMobAdapter"> //* 6 13:aload_0 //* 7 14:getfield #50 <Field String zzbth> //* 8 17:invokevirtual #95 <Method boolean String.equals(Object)> //* 9 20:ifeq 42 { zzxq1.zza(zzjj, zzcln, zzclo.zzbrr); // 10 23:aload_2 // 11 24:aload_1 // 12 25:aload_0 // 13 26:getfield #52 <Field String zzcln> // 14 29:aload_0 // 15 30:getfield #54 <Field zzwx zzclo> // 16 33:getfield #100 <Field String zzwx.zzbrr> // 17 36:invokeinterface #105 <Method void zzxq.zza(zzjj, String, String)> return; // 18 41:return } try { zzxq1.zzc(zzjj, zzcln); // 19 42:aload_2 // 20 43:aload_1 // 21 44:aload_0 // 22 45:getfield #52 <Field String zzcln> // 23 48:invokeinterface #109 <Method void zzxq.zzc(zzjj, String)> return; // 24 53:return } // Misplaced declaration of an exception variable catch(zzjj zzjj) //* 25 54:astore_1 { zzakb.zzc("Fail to load ad from adapter.", ((Throwable) (zzjj))); // 26 55:ldc1 #111 <String "Fail to load ad from adapter."> // 27 57:aload_1 // 28 58:invokestatic #116 <Method void zzakb.zzc(String, Throwable)> } zza(zzbth, 0); // 29 61:aload_0 // 30 62:aload_0 // 31 63:getfield #50 <Field String zzbth> // 32 66:iconst_0 // 33 67:invokevirtual #119 <Method void zza(String, int)> return; // 34 70:return } static String zzb(zzahn zzahn1) { return zzahn1.zzcln; // 0 0:aload_0 // 1 1:getfield #52 <Field String zzcln> // 2 4:areturn } private final boolean zzf(long l) { l = zzclp - (zzbv.zzer().elapsedRealtime() - l); // 0 0:aload_0 // 1 1:getfield #67 <Field long zzclp> // 2 4:invokestatic #131 <Method Clock zzbv.zzer()> // 3 7:invokeinterface #137 <Method long Clock.elapsedRealtime()> // 4 12:lload_1 // 5 13:lsub // 6 14:lsub // 7 15:lstore_1 if(l > 0L) goto _L2; else goto _L1 // 8 16:lload_1 // 9 17:lconst_0 // 10 18:lcmp // 11 19:ifgt 31 _L1: int i = 4; // 12 22:iconst_4 // 13 23:istore_3 _L4: mErrorCode = i; // 14 24:aload_0 // 15 25:iload_3 // 16 26:putfield #46 <Field int mErrorCode> return false; // 17 29:iconst_0 // 18 30:ireturn _L2: mLock.wait(l); // 19 31:aload_0 // 20 32:getfield #63 <Field Object mLock> // 21 35:lload_1 // 22 36:invokevirtual #141 <Method void Object.wait(long)> return true; // 23 39:iconst_1 // 24 40:ireturn _L5: Thread.currentThread().interrupt(); // 25 41:invokestatic #147 <Method Thread Thread.currentThread()> // 26 44:invokevirtual #150 <Method void Thread.interrupt()> i = 5; // 27 47:iconst_5 // 28 48:istore_3 if(true) goto _L4; else goto _L3 // 29 49:goto 24 _L3: InterruptedException interruptedexception; interruptedexception; // 30 52:astore 4 goto _L5 //* 31 54:goto 41 } public final void onStop() { // 0 0:return } public final void zza(zzb zzb1) { zzclt = zzb1; // 0 0:aload_0 // 1 1:aload_1 // 2 2:putfield #154 <Field zzb zzclt> // 3 5:return } public final void zza(String s, int i) { synchronized(mLock) //* 0 0:aload_0 //* 1 1:getfield #63 <Field Object mLock> //* 2 4:astore_1 //* 3 5:aload_1 //* 4 6:monitorenter { zzclq = 2; // 5 7:aload_0 // 6 8:iconst_2 // 7 9:putfield #44 <Field int zzclq> mErrorCode = i; // 8 12:aload_0 // 9 13:iload_2 // 10 14:putfield #46 <Field int mErrorCode> mLock.notify(); // 11 17:aload_0 // 12 18:getfield #63 <Field Object mLock> // 13 21:invokevirtual #157 <Method void Object.notify()> } // 14 24:aload_1 // 15 25:monitorexit return; // 16 26:return exception; // 17 27:astore_3 s; // 18 28:aload_1 JVM INSTR monitorexit ; // 19 29:monitorexit throw exception; // 20 30:aload_3 // 21 31:athrow } public final void zzac(int i) { zza(zzbth, 0); // 0 0:aload_0 // 1 1:aload_0 // 2 2:getfield #50 <Field String zzbth> // 3 5:iconst_0 // 4 6:invokevirtual #119 <Method void zza(String, int)> // 5 9:return } public final void zzc(Bundle bundle) { zzb zzb1 = zzclt; // 0 0:aload_0 // 1 1:getfield #154 <Field zzb zzclt> // 2 4:astore_2 if(zzb1 != null) //* 3 5:aload_2 //* 4 6:ifnull 18 zzb1.zza("", bundle); // 5 9:aload_2 // 6 10:ldc1 #162 <String ""> // 7 12:aload_1 // 8 13:invokeinterface #167 <Method void zzb.zza(String, Bundle)> // 9 18:return } public final void zzcb(String s) { synchronized(mLock) //* 0 0:aload_0 //* 1 1:getfield #63 <Field Object mLock> //* 2 4:astore_1 //* 3 5:aload_1 //* 4 6:monitorenter { zzclq = 1; // 5 7:aload_0 // 6 8:iconst_1 // 7 9:putfield #44 <Field int zzclq> mLock.notify(); // 8 12:aload_0 // 9 13:getfield #63 <Field Object mLock> // 10 16:invokevirtual #157 <Method void Object.notify()> } // 11 19:aload_1 // 12 20:monitorexit return; // 13 21:return exception; // 14 22:astore_2 s; // 15 23:aload_1 JVM INSTR monitorexit ; // 16 24:monitorexit throw exception; // 17 25:aload_2 // 18 26:athrow } public final void zzdn() { Object obj1; zzahv zzahv1; zzxq zzxq1; if(zzcll == null || zzcll.zzpf() == null) break MISSING_BLOCK_LABEL_388; // 0 0:aload_0 // 1 1:getfield #58 <Field zzaib zzcll> // 2 4:ifnull 388 // 3 7:aload_0 // 4 8:getfield #58 <Field zzaib zzcll> // 5 11:invokevirtual #82 <Method zzahv zzaib.zzpf()> // 6 14:ifnull 388 if(zzcll.zzpe() == null) //* 7 17:aload_0 //* 8 18:getfield #58 <Field zzaib zzcll> //* 9 21:invokevirtual #174 <Method zzxq zzaib.zzpe()> //* 10 24:ifnonnull 28 return; // 11 27:return zzahv1 = zzcll.zzpf(); // 12 28:aload_0 // 13 29:getfield #58 <Field zzaib zzcll> // 14 32:invokevirtual #82 <Method zzahv zzaib.zzpf()> // 15 35:astore 6 zzahv1.zza(((zzahw) (null))); // 16 37:aload 6 // 17 39:aconst_null // 18 40:invokevirtual #87 <Method void zzahv.zza(zzahw)> zzahv1.zza(((zzaht) (this))); // 19 43:aload 6 // 20 45:aload_0 // 21 46:invokevirtual #177 <Method void zzahv.zza(zzaht)> zzahv1.zza(((zzaia) (this))); // 22 49:aload 6 // 23 51:aload_0 // 24 52:invokevirtual #180 <Method void zzahv.zza(zzaia)> obj1 = ((Object) (zzbze.zzcgs.zzccv)); // 25 55:aload_0 // 26 56:getfield #56 <Field zzaji zzbze> // 27 59:getfield #186 <Field zzaef zzaji.zzcgs> // 28 62:getfield #192 <Field zzjj zzaef.zzccv> // 29 65:astore 5 zzxq1 = zzcll.zzpe(); // 30 67:aload_0 // 31 68:getfield #58 <Field zzaib zzcll> // 32 71:invokevirtual #174 <Method zzxq zzaib.zzpe()> // 33 74:astore 7 if(!zzxq1.isInitialized()) goto _L2; else goto _L1 // 34 76:aload 7 // 35 78:invokeinterface #196 <Method boolean zzxq.isInitialized()> // 36 83:ifeq 116 _L1: Object obj; obj = ((Object) (zzamu.zzsy)); // 37 86:getstatic #202 <Field Handler zzamu.zzsy> // 38 89:astore 4 obj1 = ((Object) (new zzaho(this, ((zzjj) (obj1)), zzxq1))); // 39 91:new #204 <Class zzaho> // 40 94:dup // 41 95:aload_0 // 42 96:aload 5 // 43 98:aload 7 // 44 100:invokespecial #206 <Method void zzaho(zzahn, zzjj, zzxq)> // 45 103:astore 5 _L4: ((Handler) (obj)).post(((Runnable) (obj1))); // 46 105:aload 4 // 47 107:aload 5 // 48 109:invokevirtual #212 <Method boolean Handler.post(Runnable)> // 49 112:pop break MISSING_BLOCK_LABEL_158; // 50 113:goto 158 _L2: obj = ((Object) (zzamu.zzsy)); // 51 116:getstatic #202 <Field Handler zzamu.zzsy> // 52 119:astore 4 obj1 = ((Object) (new zzahp(this, zzxq1, ((zzjj) (obj1)), zzahv1))); // 53 121:new #214 <Class zzahp> // 54 124:dup // 55 125:aload_0 // 56 126:aload 7 // 57 128:aload 5 // 58 130:aload 6 // 59 132:invokespecial #217 <Method void zzahp(zzahn, zzxq, zzjj, zzahv)> // 60 135:astore 5 if(true) goto _L4; else goto _L3 // 61 137:goto 105 _L3: RemoteException remoteexception; remoteexception; // 62 140:astore 4 zzakb.zzc("Fail to check if adapter is initialized.", ((Throwable) (remoteexception))); // 63 142:ldc1 #219 <String "Fail to check if adapter is initialized."> // 64 144:aload 4 // 65 146:invokestatic #116 <Method void zzakb.zzc(String, Throwable)> zza(zzbth, 0); // 66 149:aload_0 // 67 150:aload_0 // 68 151:getfield #50 <Field String zzbth> // 69 154:iconst_0 // 70 155:invokevirtual #119 <Method void zza(String, int)> long l = zzbv.zzer().elapsedRealtime(); // 71 158:invokestatic #131 <Method Clock zzbv.zzer()> // 72 161:invokeinterface #137 <Method long Clock.elapsedRealtime()> // 73 166:lstore_2 _L10: remoteexception = ((RemoteException) (mLock)); // 74 167:aload_0 // 75 168:getfield #63 <Field Object mLock> // 76 171:astore 4 remoteexception; // 77 173:aload 4 JVM INSTR monitorenter ; // 78 175:monitorenter if(zzclq == 0) goto _L6; else goto _L5 // 79 176:aload_0 // 80 177:getfield #44 <Field int zzclq> // 81 180:ifeq 260 _L5: obj1 = ((Object) ((new zzahs()).zzg(zzbv.zzer().elapsedRealtime() - l))); // 82 183:new #221 <Class zzahs> // 83 186:dup // 84 187:invokespecial #222 <Method void zzahs()> // 85 190:invokestatic #131 <Method Clock zzbv.zzer()> // 86 193:invokeinterface #137 <Method long Clock.elapsedRealtime()> // 87 198:lload_2 // 88 199:lsub // 89 200:invokevirtual #226 <Method zzahs zzahs.zzg(long)> // 90 203:astore 5 int i; if(1 == zzclq) //* 91 205:iconst_1 //* 92 206:aload_0 //* 93 207:getfield #44 <Field int zzclq> //* 94 210:icmpne 219 { i = 6; // 95 213:bipush 6 // 96 215:istore_1 break MISSING_BLOCK_LABEL_224; // 97 216:goto 224 } i = mErrorCode; // 98 219:aload_0 // 99 220:getfield #46 <Field int mErrorCode> // 100 223:istore_1 zzclr = ((zzahs) (obj1)).zzad(i).zzcc(zzbth).zzcd(zzclo.zzbru).zzpd(); // 101 224:aload_0 // 102 225:aload 5 // 103 227:iload_1 // 104 228:invokevirtual #230 <Method zzahs zzahs.zzad(int)> // 105 231:aload_0 // 106 232:getfield #50 <Field String zzbth> // 107 235:invokevirtual #234 <Method zzahs zzahs.zzcc(String)> // 108 238:aload_0 // 109 239:getfield #54 <Field zzwx zzclo> // 110 242:getfield #237 <Field String zzwx.zzbru> // 111 245:invokevirtual #240 <Method zzahs zzahs.zzcd(String)> // 112 248:invokevirtual #244 <Method zzahq zzahs.zzpd()> // 113 251:putfield #246 <Field zzahq zzclr> _L8: remoteexception; // 114 254:aload 4 JVM INSTR monitorexit ; // 115 256:monitorexit goto _L7 //* 116 257:goto 322 _L6: if(zzf(l)) break MISSING_BLOCK_LABEL_374; // 117 260:aload_0 // 118 261:lload_2 // 119 262:invokespecial #248 <Method boolean zzf(long)> // 120 265:ifne 374 zzclr = (new zzahs()).zzad(mErrorCode).zzg(zzbv.zzer().elapsedRealtime() - l).zzcc(zzbth).zzcd(zzclo.zzbru).zzpd(); // 121 268:aload_0 // 122 269:new #221 <Class zzahs> // 123 272:dup // 124 273:invokespecial #222 <Method void zzahs()> // 125 276:aload_0 // 126 277:getfield #46 <Field int mErrorCode> // 127 280:invokevirtual #230 <Method zzahs zzahs.zzad(int)> // 128 283:invokestatic #131 <Method Clock zzbv.zzer()> // 129 286:invokeinterface #137 <Method long Clock.elapsedRealtime()> // 130 291:lload_2 // 131 292:lsub // 132 293:invokevirtual #226 <Method zzahs zzahs.zzg(long)> // 133 296:aload_0 // 134 297:getfield #50 <Field String zzbth> // 135 300:invokevirtual #234 <Method zzahs zzahs.zzcc(String)> // 136 303:aload_0 // 137 304:getfield #54 <Field zzwx zzclo> // 138 307:getfield #237 <Field String zzwx.zzbru> // 139 310:invokevirtual #240 <Method zzahs zzahs.zzcd(String)> // 140 313:invokevirtual #244 <Method zzahq zzahs.zzpd()> // 141 316:putfield #246 <Field zzahq zzclr> goto _L8 //* 142 319:goto 254 _L7: zzahv1.zza(((zzahw) (null))); // 143 322:aload 6 // 144 324:aconst_null // 145 325:invokevirtual #87 <Method void zzahv.zza(zzahw)> zzahv1.zza(((zzaht) (null))); // 146 328:aload 6 // 147 330:aconst_null // 148 331:invokevirtual #177 <Method void zzahv.zza(zzaht)> if(zzclq == 1) //* 149 334:aload_0 //* 150 335:getfield #44 <Field int zzclq> //* 151 338:iconst_1 //* 152 339:icmpne 356 { zzclm.zzcb(zzbth); // 153 342:aload_0 // 154 343:getfield #65 <Field zzahw zzclm> // 155 346:aload_0 // 156 347:getfield #50 <Field String zzbth> // 157 350:invokeinterface #250 <Method void zzahw.zzcb(String)> return; // 158 355:return } else { zzclm.zza(zzbth, mErrorCode); // 159 356:aload_0 // 160 357:getfield #65 <Field zzahw zzclm> // 161 360:aload_0 // 162 361:getfield #50 <Field String zzbth> // 163 364:aload_0 // 164 365:getfield #46 <Field int mErrorCode> // 165 368:invokeinterface #251 <Method void zzahw.zza(String, int)> return; // 166 373:return } remoteexception; // 167 374:aload 4 JVM INSTR monitorexit ; // 168 376:monitorexit if(true) goto _L10; else goto _L9 // 169 377:goto 167 _L9: Exception exception; exception; // 170 380:astore 5 remoteexception; // 171 382:aload 4 JVM INSTR monitorexit ; // 172 384:monitorexit throw exception; // 173 385:aload 5 // 174 387:athrow // 175 388:return } public final Future zzoz() { if(zzcls != null) //* 0 0:aload_0 //* 1 1:getfield #255 <Field Future zzcls> //* 2 4:ifnull 12 { return zzcls; // 3 7:aload_0 // 4 8:getfield #255 <Field Future zzcls> // 5 11:areturn } else { zzanz zzanz1 = (zzanz)((zzajx)this).zznt(); // 6 12:aload_0 // 7 13:invokevirtual #259 <Method Object zzajx.zznt()> // 8 16:checkcast #261 <Class zzanz> // 9 19:astore_1 zzcls = ((Future) (zzanz1)); // 10 20:aload_0 // 11 21:aload_1 // 12 22:putfield #255 <Field Future zzcls> return ((Future) (zzanz1)); // 13 25:aload_1 // 14 26:areturn } } public final zzahq zzpa() { zzahq zzahq; synchronized(mLock) //* 0 0:aload_0 //* 1 1:getfield #63 <Field Object mLock> //* 2 4:astore_1 //* 3 5:aload_1 //* 4 6:monitorenter { zzahq = zzclr; // 5 7:aload_0 // 6 8:getfield #246 <Field zzahq zzclr> // 7 11:astore_2 } // 8 12:aload_1 // 9 13:monitorexit return zzahq; // 10 14:aload_2 // 11 15:areturn exception; // 12 16:astore_2 obj; // 13 17:aload_1 JVM INSTR monitorexit ; // 14 18:monitorexit throw exception; // 15 19:aload_2 // 16 20:athrow } public final zzwx zzpb() { return zzclo; // 0 0:aload_0 // 1 1:getfield #54 <Field zzwx zzclo> // 2 4:areturn } public final void zzpc() { zza(zzbze.zzcgs.zzccv, zzcll.zzpe()); // 0 0:aload_0 // 1 1:aload_0 // 2 2:getfield #56 <Field zzaji zzbze> // 3 5:getfield #186 <Field zzaef zzaji.zzcgs> // 4 8:getfield #192 <Field zzjj zzaef.zzccv> // 5 11:aload_0 // 6 12:getfield #58 <Field zzaib zzcll> // 7 15:invokevirtual #174 <Method zzxq zzaib.zzpe()> // 8 18:invokespecial #74 <Method void zza(zzjj, zzxq)> // 9 21:return } private final Context mContext; private int mErrorCode; private final Object mLock = new Object(); public final String zzbth; private final zzaji zzbze; private final zzaib zzcll; private final zzahw zzclm; private final String zzcln; private final zzwx zzclo; private final long zzclp; private int zzclq; private zzahq zzclr; private Future zzcls; private volatile zzb zzclt; }
YourFantasy/LeetCode
src/main/java/com/hust/edu/cn/twoPointers/_713.java
<filename>src/main/java/com/hust/edu/cn/twoPointers/_713.java package com.hust.edu.cn.twoPointers; class _713 { /** * j为工作指针 * i始终指向当b<k时的起始位置,并且此时i在j处或者j前面 * 设置b为数组的连续的乘积,如果b>=k,此时不满足,所以b=b/nums[i]; * 设数组为a0,a1,a2,a3....ak,...am...an;如果ak*ak+1*...am<k,此时的个数为cnt,若ak*ak+1*...am*am+1<k, 此时的个数为cnt+m+1-k+1 */ public int numSubarrayProductLessThanK(int[] nums, int k) { int cnt = 0; int i = 0, j = 0; int b = 1; while (j < nums.length) { b *= nums[j]; while (i <= j && b >= k) { b = b / nums[i]; i++; } cnt += j - i + 1;//当(b<k)时的个数,如果b==1.此时表明单个元素的指都大于k,所以此时的个数为0; j++; } return cnt; } }
Sonicskater/CurveModeller
src/vbo_tools.cpp
/** * @author <NAME>, <NAME> * @date 2019-10-15. * @details Organization: Biological Modeling and Visualization research group * University of Calgary, Calgary, AB, Canada * * Contact: arowens [at] ucalgary.ca * @copyright Copyright (c) 2019 ___ALGORITHMIC_BOTANY___. All rights reserved. * * @brief */ #include "vbo_tools.hpp" #include <algorithm> #include <unordered_map> #include <fstream> #include <iostream> #include <map> #include "glad/glad.h" // Wont work for meshes that are in excess of #v * #uv * #n > max(size_t) // but that is around the mark of 10,000,000 x 10,000,000 x 1,000,000, // so we are probably fine namespace opengl { VBOData_Vertices makeConsistentVertexIndices(geometry::OBJMesh const &mesh) { // simply copy the indices.. std::vector<unsigned int> indices; indices.resize(mesh.triangles.size() * 3); // strip out just vertex IDs for (auto const &t : mesh.triangles) { indices.emplace_back(t.a().vertexID()); indices.emplace_back(t.b().vertexID()); indices.emplace_back(t.c().vertexID()); } return {indices, mesh.vertices}; } VBOData_VerticesNormals makeConsistentVertexNormalIndices(geometry::OBJMesh const &mesh, geometry::Normals vertexNormals) { // simply copy the indices.. std::vector<unsigned int> indices; indices.resize(mesh.triangles.size() * 3); // strip out just vertex IDs for (auto const &t : mesh.triangles) { indices.emplace_back(t.a().vertexID()); indices.emplace_back(t.b().vertexID()); indices.emplace_back(t.c().vertexID()); } return {indices, mesh.vertices, vertexNormals}; } VBOData_VerticesNormals makeConsistentVertexNormalIndices(geometry::OBJMesh const &mesh) { std::unordered_map<size_t, unsigned int> mappedIndices; mappedIndices.reserve(mesh.vertices.size()); std::vector<unsigned int> indicesOut; indicesOut.reserve(mesh.triangles.size() * 3); // avoid early resize growth penalty std::vector<math::Vec3f> verticesOut; verticesOut.reserve(mesh.vertices.size()); // at least this many vertices std::vector<math::Vec3f> normalsOut; normalsOut.reserve(verticesOut.size()); // at least this many normals auto verticesIDRange = mesh.vertices.size(); auto normalsIDRange = mesh.normals.size(); auto keyGen = [verticesIDRange, normalsIDRange](unsigned int vertexID, unsigned int normalID) { return vertexID + verticesIDRange * normalID; }; for (auto const &t : mesh.triangles) { for (int idx = 0; idx < 3; ++idx) { auto index = t[idx]; auto key = keyGen(index.vertexID(), index.textureCoordID()); auto iter = mappedIndices.find(key); if (iter != mappedIndices.end()) { indicesOut.push_back(iter->second); // reuse id } else { unsigned int id = verticesOut.size(); indicesOut.push_back(id); // new id verticesOut.push_back(mesh.vertices[index.vertexID()]); normalsOut.push_back(mesh.normals[index.normalID()]); mappedIndices[key] = id; // save for next } } } // optional indicesOut.shrink_to_fit(); verticesOut.shrink_to_fit(); normalsOut.shrink_to_fit(); return {indicesOut, verticesOut, normalsOut}; } VBOData_VerticesTexutreCoordsNormals makeConsistentVertexTextureCoordNormalIndices( geometry::OBJMesh const &mesh, geometry::Normals const &vertexNormals) { std::unordered_map<size_t, unsigned int> mappedIndices; mappedIndices.reserve(mesh.vertices.size()); std::vector<unsigned int> indicesOut; indicesOut.reserve(mesh.triangles.size() * 3); // avoid early resize growth penalty std::vector<math::Vec3f> verticesOut; verticesOut.reserve(mesh.vertices.size()); // at least this many vertices std::vector<math::Vec2f> textureCoordsOut; textureCoordsOut.reserve( mesh.vertices.size()); // at least this many textureCoords std::vector<math::Vec3f> normalsOut; normalsOut.reserve(vertexNormals.size()); // at least this many normals auto verticesIDRange = mesh.vertices.size(); auto textureCoordsIDRange = mesh.textureCoords.size(); // auto normalsIDRange = normals.size(); // not needed auto keyGen = [verticesIDRange, textureCoordsIDRange]( unsigned int vertexID, unsigned int textureCoordID) -> size_t { return vertexID + verticesIDRange * textureCoordID; }; for (auto const &t : mesh.triangles) { for (int idx = 0; idx < 3; ++idx) { auto index = t[idx]; auto key = keyGen(index.vertexID(), index.textureCoordID()); // index.normalID()); auto iter = mappedIndices.find(key); if (iter != mappedIndices.end()) { auto vID = iter->second; // reuse existing id indicesOut.push_back(vID); } else { unsigned int id = verticesOut.size(); indicesOut.push_back(id); // new id verticesOut.push_back(mesh.vertices[index.vertexID()]); textureCoordsOut.push_back(mesh.textureCoords[index.textureCoordID()]); normalsOut.push_back(vertexNormals[index.vertexID()]); mappedIndices[key] = id; } } } // optional indicesOut.shrink_to_fit(); verticesOut.shrink_to_fit(); textureCoordsOut.shrink_to_fit(); normalsOut.shrink_to_fit(); return {indicesOut, verticesOut, textureCoordsOut, normalsOut}; } VBOData_VerticesTexutreCoordsNormals makeConsistentVertexTextureCoordNormalIndices(geometry::OBJMesh const &mesh) { std::unordered_map<size_t, unsigned int> mappedIndices; // std::map<size_t, unsigned int> mappedIndices; mappedIndices.reserve(mesh.vertices.size()); std::vector<unsigned int> indicesOut; indicesOut.reserve(mesh.triangles.size() * 3); std::vector<math::Vec3f> verticesOut; verticesOut.reserve(mesh.vertices.size()); // at least this many vertices std::vector<math::Vec2f> textureCoordsOut; textureCoordsOut.reserve(mesh.vertices.size()); // at least this many std::vector<math::Vec3f> normalsOut; normalsOut.reserve(mesh.vertices.size()); // at least this many normals auto verticesIDRange = mesh.vertices.size(); auto textureCoordsIDRange = mesh.textureCoords.size(); // auto normalsIDRange = normals.size(); // not needed auto keyGen = [verticesIDRange, textureCoordsIDRange]( unsigned int vertexID, unsigned int textureCoordID, unsigned int normalID) -> size_t { return vertexID + verticesIDRange * textureCoordID + (verticesIDRange * textureCoordsIDRange) * normalID; }; for (auto const &t : mesh.triangles) { for (int idx = 0; idx < 3; ++idx) { auto index = t[idx]; auto key = keyGen(index.vertexID(), index.textureCoordID(), index.normalID()); auto iter = mappedIndices.find(key); if (iter != mappedIndices.end()) { auto vID = iter->second; // reuse existing id indicesOut.push_back(vID); } else { unsigned int id = verticesOut.size(); indicesOut.push_back(id); // new id verticesOut.push_back(mesh.vertices[index.vertexID()]); textureCoordsOut.push_back(mesh.textureCoords[index.textureCoordID()]); normalsOut.push_back(mesh.normals[index.normalID()]); mappedIndices[key] = id; } } } // optional indicesOut.shrink_to_fit(); verticesOut.shrink_to_fit(); textureCoordsOut.shrink_to_fit(); normalsOut.shrink_to_fit(); return {indicesOut, verticesOut, textureCoordsOut, normalsOut}; } unsigned int setup_vao_and_buffers(opengl::VertexArrayObject &vao, opengl::BufferObject &indexBuffer, opengl::BufferObject &vertexBuffer, opengl::VBOData_Vertices const &data) { using namespace opengl; vao.bind(); auto indexSize = sizeof(unsigned int) * (data.indices.size()); indexBuffer.bind(BufferObject::ELEMENT_ARRAY); glBufferData(GL_ELEMENT_ARRAY_BUFFER, // type indexSize, // size data.indices.data(), // data GL_STATIC_DRAW); // set up position input into vertex shader auto vertexSize = sizeof(math::Vec3f) * data.vertices.size(); auto totalSize = vertexSize; auto vertexOffset = size_t(0); vertexBuffer.bind(BufferObject::ARRAY); // positions glEnableVertexAttribArray(0); // match layout # in vertex shader glVertexAttribPointer( // 0, // attribute layout # (in shader) 3, // number of coordinates per vertex GL_FLOAT, // type GL_FALSE, // normalized? sizeof(math::Vec3f), // stride (void *)(vertexOffset) // array buffer offset ); // request storage, but provide no data // [ vertices | normals | uvs ] glBufferData(GL_ARRAY_BUFFER, totalSize, NULL, GL_STATIC_DRAW); // load positions // [ v | v | v | ] glBufferSubData(GL_ARRAY_BUFFER, // type 0, // offset vertexSize, // size data.vertices.data()); // data pointer vao.unbind(); indexBuffer.unbind(); vertexBuffer.unbind(); return data.indices.size(); } unsigned int setup_vao_and_buffers(opengl::VertexArrayObject &vao, opengl::BufferObject &indexBuffer, opengl::BufferObject &vertexBuffer, VBOData_VerticesNormals const &data) { using namespace opengl; vao.bind(); // bind these indices auto indexSize = sizeof(unsigned int) * (data.indices.size()); indexBuffer.bind(BufferObject::ELEMENT_ARRAY); glBufferData(GL_ELEMENT_ARRAY_BUFFER, // type indexSize, // size data.indices.data(), // data GL_STATIC_DRAW); // set up position input into vertex shader auto vertexSize = sizeof(math::Vec3f) * data.vertices.size(); auto normalsSize = sizeof(math::Vec3f) * data.normals.size(); auto totalSize = vertexSize + normalsSize; auto verticesOffset = size_t(0); auto normalsOffset = vertexSize; vertexBuffer.bind(BufferObject::ARRAY); // vao setup // positions glEnableVertexAttribArray(0); // match layout # in vertex shader glVertexAttribPointer( // 0, // attribute layout # (in shader) 3, // number of coordinates per vertex GL_FLOAT, // type GL_FALSE, // normalized? sizeof(math::Vec3f), // stride (void *)(verticesOffset) // array buffer offset ); // normals glEnableVertexAttribArray(1); // match layout # in vertex shader glVertexAttribPointer( // 1, // attribute layout # (in shader) 3, // number of coordinates per vertex GL_FLOAT, // type GL_FALSE, // normalized? sizeof(math::Vec3f), // stride (void *)(normalsOffset) // array buffer offset ); // request storage, but provide no data // [ vertices | normals | uvs ] glBufferData(GL_ARRAY_BUFFER, totalSize, NULL, GL_STATIC_DRAW); // load positions // [ v | v | v | ... | *uninitialized* ] glBufferSubData(GL_ARRAY_BUFFER, // type verticesOffset, // offset vertexSize, // size data.vertices.data()); // data pointer // load normals // [ v | v | v | ... | n | n | n | ] glBufferSubData(GL_ARRAY_BUFFER, // type normalsOffset, // offset normalsSize, // size data.normals.data()); // data pointer vao.unbind(); indexBuffer.unbind(); vertexBuffer.unbind(); return data.indices.size(); } unsigned int setup_vao_and_buffers(opengl::VertexArrayObject &vao, opengl::BufferObject &indexBuffer, opengl::BufferObject &vertexBuffer, VBOData_VerticesTexutreCoordsNormals const &data) { using namespace opengl; vao.bind(); // bind these indices auto indexSize = sizeof(unsigned int) * (data.indices.size()); indexBuffer.bind(BufferObject::ELEMENT_ARRAY); glBufferData(GL_ELEMENT_ARRAY_BUFFER, // type indexSize, // size data.indices.data(), // data GL_STATIC_DRAW); // set up position input into vertex shader auto vertexSize = sizeof(math::Vec3f) * data.vertices.size(); auto textureCoordSize = sizeof(math::Vec2f) * data.textureCoords.size(); auto normalsSize = sizeof(math::Vec3f) * data.normals.size(); auto totalSize = vertexSize + normalsSize + textureCoordSize; auto verticesOffset = size_t(0); auto normalsOffset = vertexSize; auto textureCoordsOffset = vertexSize + normalsSize; vertexBuffer.bind(BufferObject::ARRAY); // vao setup // positions glEnableVertexAttribArray(0); // match layout # in vertex shader glVertexAttribPointer( // 0, // attribute layout # (in shader) 3, // number of coordinates per vertex GL_FLOAT, // type GL_FALSE, // normalized? sizeof(math::Vec3f), // stride (void *)(verticesOffset) // array buffer offset ); // normals glEnableVertexAttribArray(1); // match layout # in vertex shader glVertexAttribPointer( // 1, // attribute layout # (in shader) 3, // number of coordinates per vertex GL_FLOAT, // type GL_FALSE, // normalized? sizeof(math::Vec3f), // stride (void *)(normalsOffset) // array buffer offset ); // texture coords glEnableVertexAttribArray(2); // match layout # in vertex shader glVertexAttribPointer( // 2, // attribute layout # (in shader) 2, // number of coordinates per vertex GL_FLOAT, // type GL_FALSE, // normalized? sizeof(math::Vec2f), // stride (void *)(textureCoordsOffset) // array buffer offset ); // request storage, but provide no data // [ vertices| uvs | normals ] glBufferData(GL_ARRAY_BUFFER, totalSize, NULL, GL_STATIC_DRAW); // load positions // [ v | v | v | ... | *uninitialized* ] glBufferSubData(GL_ARRAY_BUFFER, // type verticesOffset, // offset vertexSize, // size data.vertices.data()); // data pointer // load normals // [ v | v | v | .. | n | n | n | ... | *unitialized* ] glBufferSubData(GL_ARRAY_BUFFER, // type normalsOffset, // offset normalsSize, // size data.normals.data()); // data pointer // load uvs // [ v | v | v | .. | n | n | n | ... | uv | uv | uv ] glBufferSubData(GL_ARRAY_BUFFER, // type textureCoordsOffset, // offset textureCoordSize, // size data.textureCoords.data()); // data pointer vao.unbind(); indexBuffer.unbind(); vertexBuffer.unbind(); return data.indices.size(); } } // namespace opengl
xiangxik/castle-cloud
castle-component/castle-service-provider/src/main/java/me/xiangxik/service/provider/FooController.java
package me.xiangxik.service.provider; import java.util.Date; import javax.servlet.http.HttpServletRequest; import org.springframework.web.bind.annotation.PathVariable; import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RequestMethod; import org.springframework.web.bind.annotation.RestController; @RestController public class FooController { @RequestMapping(value = "/call/{id}", method = RequestMethod.GET) public Foo call(@PathVariable Integer id, HttpServletRequest request) { // try { // Thread.sleep(2500); // } catch (InterruptedException e) { // // TODO Auto-generated catch block // e.printStackTrace(); // } Foo foo = new Foo(); foo.setId(id); foo.setName("ttt"); foo.setAge(12); foo.setLastModifiedDate(new Date()); foo.setMessage(request.getRequestURL().toString()); return foo; } }
raugfer/glasses
classes/java/security/AccessControlException.java
<gh_stars>0 /* GLASSES, Generic cLASSES * Copyright (c) 1998-2004, <NAME> */ package java.security; public class AccessControlException extends SecurityException { private final Permission permission; public AccessControlException(String message) { this(message, null); } public AccessControlException(String message, Permission permission) { super(message); this.permission = permission; } public Permission getPermission() { return permission; } }
random-mud-pie/CoffeeMud
com/planet_ink/coffee_mud/Items/Basic/HoleInTheGround.java
package com.planet_ink.coffee_mud.Items.Basic; import com.planet_ink.coffee_mud.core.interfaces.*; import com.planet_ink.coffee_mud.core.*; import com.planet_ink.coffee_mud.core.collections.*; import com.planet_ink.coffee_mud.Abilities.interfaces.*; import com.planet_ink.coffee_mud.Areas.interfaces.*; import com.planet_ink.coffee_mud.Behaviors.interfaces.*; import com.planet_ink.coffee_mud.CharClasses.interfaces.*; import com.planet_ink.coffee_mud.Commands.interfaces.*; import com.planet_ink.coffee_mud.Common.interfaces.*; import com.planet_ink.coffee_mud.Exits.interfaces.*; import com.planet_ink.coffee_mud.Items.interfaces.*; import com.planet_ink.coffee_mud.Libraries.interfaces.*; import com.planet_ink.coffee_mud.Locales.interfaces.*; import com.planet_ink.coffee_mud.MOBS.interfaces.*; import com.planet_ink.coffee_mud.Races.interfaces.*; /* Copyright 2011-2019 <NAME> Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. */ public class HoleInTheGround extends GenContainer { @Override public String ID() { return "HoleInTheGround"; } public HoleInTheGround() { super(); setName("a hole in the ground"); setDisplayText("a hole in the ground"); setDescription("Looks like someone has dug hole here. Perhaps something is in it?"); capacity=0; baseGoldValue=0; basePhyStats().setWeight(0); basePhyStats().setSensesMask(basePhyStats.sensesMask() |PhyStats.SENSE_ITEMNOTGET |PhyStats.SENSE_ITEMNOWISH |PhyStats.SENSE_ITEMNORUIN |PhyStats.SENSE_UNLOCATABLE); basePhyStats.setDisposition(basePhyStats.disposition() |PhyStats.IS_UNSAVABLE |PhyStats.IS_NOT_SEEN); setMaterial(RawMaterial.RESOURCE_DUST); recoverPhyStats(); } @Override public boolean okMessage(final Environmental myHost, final CMMsg msg) { if(msg.amITarget(owner())) { switch(msg.targetMinor()) { case CMMsg.TYP_ENTER: case CMMsg.TYP_LEAVE: case CMMsg.TYP_RECALL: if((owner() instanceof Room) &&(((Room)owner()).numPCInhabitants()==0)) { if(!hasContent()) { destroy(); return true; } else { basePhyStats().setDisposition(basePhyStats().disposition()|PhyStats.IS_HIDDEN); recoverPhyStats(); } } break; case CMMsg.TYP_EXPIRE: if(hasContent()) { return false; } break; } } else if(msg.amITarget(this)) { switch(msg.targetMinor()) { case CMMsg.TYP_CLOSE: msg.setSourceMessage("<S-NAME> fill(s) the hole back in."); msg.setOthersMessage("<S-NAME> fill(s) the hole back in."); return true; case CMMsg.TYP_PUT: if((msg.tool() instanceof Item)) { if((readableText().length()>0)&&(!readableText().equals(msg.source().Name()))) { msg.source().tell(L("Go find your own hole.")); return false; } } if((msg.tool() instanceof ClanItem)) { msg.source().tell(L("Go may not bury a clan item.")); return false; } break; } } return super.okMessage(myHost, msg); } @Override public void executeMsg(final Environmental myHost, final CMMsg msg) { if(msg.target()==owner()) { switch(msg.targetMinor()) { case CMMsg.TYP_DIG: if(CMath.bset(basePhyStats().disposition(), PhyStats.IS_NOT_SEEN) ||CMath.bset(basePhyStats().disposition(), PhyStats.IS_HIDDEN)) { basePhyStats().setDisposition(CMath.unsetb(basePhyStats().disposition(), PhyStats.IS_NOT_SEEN)); basePhyStats().setDisposition(CMath.unsetb(basePhyStats().disposition(), PhyStats.IS_HIDDEN)); recoverPhyStats(); } setCapacity(capacity()+msg.value()); break; } } else if(msg.amITarget(this)) { final MOB mob=msg.source(); switch(msg.targetMinor()) { case CMMsg.TYP_CLOSE: if(!hasContent()) destroy(); else { basePhyStats().setDisposition(basePhyStats().disposition()|PhyStats.IS_NOT_SEEN); setCapacity(0); recoverPhyStats(); } return; case CMMsg.TYP_PUT: if((msg.tool() instanceof Item)) { final PlayerStats pstats=mob.playerStats(); if(pstats!=null) { if(readableText().length()==0) setReadableText(mob.Name()); if(!pstats.getExtItems().isContent(this)) pstats.getExtItems().addItem(this); if(msg.tool() instanceof Decayable) ((Decayable)msg.tool()).setDecayTime(((Decayable)msg.tool()).decayTime()/2); ((Item)msg.tool()).setExpirationDate(0); } } break; } } super.executeMsg(myHost, msg); } @Override public boolean sameAs(final Environmental E) { if(!(E instanceof HoleInTheGround)) return false; return super.sameAs(E); } }
physicsLoveJava/algorithms-practice-record
src/main/java/leetcode/contest/c5/SuitablePar.java
<reponame>physicsLoveJava/algorithms-practice-record<gh_stars>0 package leetcode.contest.c5; import java.util.Arrays; import java.util.Scanner; import java.util.Set; import java.util.TreeSet; public class SuitablePar { public static void main(String[] args) { Scanner scanner = new Scanner(System.in); int n = scanner.nextInt(); Set<String> list = parString(n); StringBuilder sb = new StringBuilder(); for (String s : list) { sb.append(s).append(","); } System.out.println(sb.substring(0, sb.length() - 1)); } private static Set<String> parString(int n) { if(n == 1) { return new TreeSet<>(Arrays.asList("()")); } Set<String> subList = parString(n - 1); Set<String> rs = new TreeSet<>(); for (String s : subList) { rs.add("(" + s + ")"); rs.add(s + "()"); rs.add("()" + s); } return rs; } }
sinotopia/sinotopia
sinotopia-fundamental/sinotopia-web/sinotopia-fundamental-jackson/src/main/java/com/sinotopia/fundamental/jackson/convert/serializer/DoubleJsonSerializer.java
<gh_stars>0 package com.sinotopia.fundamental.jackson.convert.serializer; /** * Double类型字段值的序列化 * Created by zhoubing on 2016/8/5. */ public class DoubleJsonSerializer extends BigDecimalJsonSerializer { public DoubleJsonSerializer() { addClazz(Double.class); addClazz(double.class); } }
g-votte/pfrl
tests/utils_tests/test_copy_param.py
<filename>tests/utils_tests/test_copy_param.py import unittest import torch import torch.nn as nn import numpy as np from pfrl.utils import copy_param from pfrl.testing import torch_assert_allclose class TestCopyParam(unittest.TestCase): def test_copy_param(self): a = nn.Linear(1, 5) b = nn.Linear(1, 5) s = torch.from_numpy(np.random.rand(1, 1).astype(np.float32)) a_out = list(a(s).detach().numpy().ravel()) b_out = list(b(s).detach().numpy().ravel()) self.assertNotEqual(a_out, b_out) # Copy b's parameters to a copy_param.copy_param(a, b) a_out_new = list(a(s).detach().numpy().ravel()) b_out_new = list(b(s).detach().numpy().ravel()) self.assertEqual(a_out_new, b_out) self.assertEqual(b_out_new, b_out) def test_copy_param_scalar(self): a = nn.Module() a.p = nn.Parameter(torch.Tensor([1])) b = nn.Module() b.p = nn.Parameter(torch.Tensor([2])) self.assertNotEqual(a.p.detach().numpy(), b.p.detach().numpy()) # Copy b's parameters to a copy_param.copy_param(a, b) self.assertEqual(a.p.detach().numpy(), b.p.detach().numpy()) def test_copy_param_shape_check(self): a = nn.Linear(2, 5) b = nn.Linear(1, 5) with self.assertRaises(RuntimeError): # Different shape copy_param.copy_param(a, b) with self.assertRaises(RuntimeError): # Different shape copy_param.copy_param(b, a) def test_soft_copy_param(self): a = nn.Linear(1, 5) b = nn.Linear(1, 5) with torch.no_grad(): a.weight.fill_(0.5) b.weight.fill_(1) # a = (1 - tau) * a + tau * b copy_param.soft_copy_param(target_link=a, source_link=b, tau=0.1) torch_assert_allclose(a.weight, torch.full_like(a.weight, 0.55)) torch_assert_allclose(b.weight, torch.full_like(b.weight, 1.0)) copy_param.soft_copy_param(target_link=a, source_link=b, tau=0.1) torch_assert_allclose(a.weight, torch.full_like(a.weight, 0.595)) torch_assert_allclose(b.weight, torch.full_like(b.weight, 1.0)) def test_soft_copy_param_scalar(self): a = nn.Module() a.p = nn.Parameter(torch.as_tensor(0.5)) b = nn.Module() b.p = nn.Parameter(torch.as_tensor(1.0)) # a = (1 - tau) * a + tau * b copy_param.soft_copy_param(target_link=a, source_link=b, tau=0.1) torch_assert_allclose(a.p, torch.full_like(a.p, 0.55)) torch_assert_allclose(b.p, torch.full_like(b.p, 1.0)) copy_param.soft_copy_param(target_link=a, source_link=b, tau=0.1) torch_assert_allclose(a.p, torch.full_like(a.p, 0.595)) torch_assert_allclose(b.p, torch.full_like(b.p, 1.0)) def test_soft_copy_param_shape_check(self): a = nn.Linear(2, 5) b = nn.Linear(1, 5) # Different shape with self.assertRaises(AssertionError): copy_param.soft_copy_param(a, b, 0.1) with self.assertRaises(AssertionError): copy_param.soft_copy_param(b, a, 0.1) def test_copy_grad(self): def set_random_grad(link): link.zero_grad() x = np.random.normal(size=(1, 1)).astype(np.float32) y = link(torch.from_numpy(x)) * np.random.normal() torch.sum(y).backward() # When source is not None and target is None a = nn.Linear(1, 5) b = nn.Linear(1, 5) set_random_grad(a) b.zero_grad() assert a.weight.grad is not None assert a.bias.grad is not None assert b.weight.grad is None assert b.bias.grad is None copy_param.copy_grad(target_link=b, source_link=a) torch_assert_allclose(a.weight.grad, b.weight.grad) torch_assert_allclose(a.bias.grad, b.bias.grad) assert a.weight.grad is not b.weight.grad assert a.bias.grad is not b.bias.grad # When both are not None a = nn.Linear(1, 5) b = nn.Linear(1, 5) set_random_grad(a) set_random_grad(b) assert a.weight.grad is not None assert a.bias.grad is not None assert b.weight.grad is not None assert b.bias.grad is not None copy_param.copy_grad(target_link=b, source_link=a) torch_assert_allclose(a.weight.grad, b.weight.grad) torch_assert_allclose(a.bias.grad, b.bias.grad) assert a.weight.grad is not b.weight.grad assert a.bias.grad is not b.bias.grad # When source is None and target is not None a = nn.Linear(1, 5) b = nn.Linear(1, 5) a.zero_grad() set_random_grad(b) assert a.weight.grad is None assert a.bias.grad is None assert b.weight.grad is not None assert b.bias.grad is not None copy_param.copy_grad(target_link=b, source_link=a) assert a.weight.grad is None assert a.bias.grad is None assert b.weight.grad is None assert b.bias.grad is None # When both are None a = nn.Linear(1, 5) b = nn.Linear(1, 5) a.zero_grad() b.zero_grad() assert a.weight.grad is None assert a.bias.grad is None assert b.weight.grad is None assert b.bias.grad is None copy_param.copy_grad(target_link=b, source_link=a) assert a.weight.grad is None assert a.bias.grad is None assert b.weight.grad is None assert b.bias.grad is None
shangliyun/lu_xing_xiang_one_os
libc/source/armlibc/libc_syms.c
/** *********************************************************************************************************************** * Copyright (c) 2020, China Mobile Communications Group Co.,Ltd. * * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on * an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the * specific language governing permissions and limitations under the License. * * @file libc_syms.c * * @brief This file export some symbols for module. * * @revision * Date Author Notes * 2020-04-14 OneOS Team First version. *********************************************************************************************************************** */ #include <stdio.h> #include <stdlib.h> #include <string.h> #include <ctype.h> #include <time.h> #include <oneos_config.h> #include <os_module.h> /* Some export routines for module. */ EXPORT_SYMBOL(strstr); EXPORT_SYMBOL(strlen); EXPORT_SYMBOL(strchr); EXPORT_SYMBOL(strcpy); EXPORT_SYMBOL(strncpy); EXPORT_SYMBOL(strcmp); EXPORT_SYMBOL(strncmp); EXPORT_SYMBOL(strcat); EXPORT_SYMBOL(strtol); EXPORT_SYMBOL(memcpy); EXPORT_SYMBOL(memcmp); EXPORT_SYMBOL(memmove); EXPORT_SYMBOL(memset); EXPORT_SYMBOL(memchr); EXPORT_SYMBOL(toupper); EXPORT_SYMBOL(atoi); #ifdef OS_USING_RTC EXPORT_SYMBOL(localtime); EXPORT_SYMBOL(time); #endif /* Import the full stdio for printf. */ #if defined(OS_USING_MODULE) && defined(__MICROLIB) #error "[OS_USING_LIBC] Please use standard libc but not microlib." #endif EXPORT_SYMBOL(puts); EXPORT_SYMBOL(printf);
osiris2k/school
src/js/app/components/video.js
<gh_stars>0 var pc_video = { init: function(){ $('body').on('click', '.video-block', function() { var element = $(this); if(element.hasClass('video-is-open')) { pc_video.close(element); } else { pc_video.open(element); } //videoWrapper.find('.fillcontainer').trigger('fill'); }); $('body').on('fill', '.fillcontainer', function() { var element = $(this); var container = element.parent(); var ratio = element.attr('data-ratio'); if (typeof (ratio) == 'undefined') { ratio = element.width() / element.height(); element.attr('data-ratio', ratio); } var newWidth = container.width(); var newHeight = newWidth / ratio; if (newHeight < container.height()) { newHeight = container.height(); newWidth = newHeight * ratio; } element.css({ width: newWidth + 1, height: newHeight }); element.css({ top: (container.height() - newHeight) / 2, left: (container.width() - newWidth) / 2 }); }); }, open: function($vdoContainer){ if($vdoContainer.find('video').length) return; var cell = $vdoContainer.closest('.sec-video'); var videoWrapper = $vdoContainer.find('.video-block-inner'); var placeholder = $vdoContainer.find('.video-placeholder'); var video = $('<video loop muted autoplay class="fillcontainer"></video>'); video.html('<source src="' + placeholder.attr('data-mp4') + '" type="video/mp4" />'); videoWrapper.append(video); $vdoContainer.delay(200).show(0,function(){ $vdoContainer.addClass('video-is-open'); }); }, close: function($vdoContainer){ if(!$vdoContainer.hasClass('video-is-open')) return; $vdoContainer.removeClass('video-is-open'); $vdoContainer.find('video').delay(400).hide(0,function(){ $vdoContainer.find('video').remove(); }); } }; //site.ready.push(pc_video.init);
drjerry/acsploit
test/exploits/graphs/min_span_tree/test_kruskal.py
<gh_stars>100-1000 from exploits.graphs.min_span_tree import kruskal from test.exploits.dummy_output import DummyOutput def test_small_kruskal(): output = DummyOutput() n_nodes = 10 kruskal.options['n_nodes'] = n_nodes kruskal.run(output) assert len(output) == n_nodes def test_large_kruskal(): output = DummyOutput() n_nodes = 1000 kruskal.options['n_nodes'] = n_nodes kruskal.run(output) assert len(output) == n_nodes
playaround88/scan
scan-redis/src/main/java/com/ai/scan/redis/ScanLauncher.java
package com.ai.scan.redis; import java.util.List; import org.slf4j.Logger; import org.slf4j.LoggerFactory; /** * 数据扫描任务的启动类 * * @author wutb * */ public class ScanLauncher { private static Logger LOG=LoggerFactory.getLogger(ScanLauncher.class); private ScanConfig config; private List<ScanThread> scanThreads; private List<DealThread> workers; public ScanLauncher(ScanConfig config){ this.config=config; } public void init(){ LOG.info("启动数据扫描任务{}",config.getIdentifier()); LOG.info("{}启动扫描线程",config.getIdentifier()); for(int i=0; i<config.getScanPoolSize(); i++){ ScanThread scanThread=new ScanThread(config); scanThread.start(); this.scanThreads.add(scanThread); } LOG.info("{}启动处理线程池",config.getIdentifier()); for(int i=0; i<config.getDealPoolSize(); i++){ DealThread worker=new DealThread(config); worker.start(); workers.add(worker); } } public void destroy(){ LOG.info("关闭数据扫描任务{}",config.getIdentifier()); LOG.info("关闭监听线程{}",config.getIdentifier()); for(ScanThread scanThread : scanThreads){ scanThread.shutdown(); } LOG.info("关闭所有处理线程{}", config.getIdentifier()); for(int i=0;i<workers.size();i++){ workers.get(i).shutdown(); } LOG.info("关闭数据扫描任务{}完成",config.getIdentifier()); } }